Handle showsize/showsizeunits independently

This commit is contained in:
Ross Scroggs
2026-03-10 09:30:50 -07:00
parent 4f992f4d41
commit ad3d4e9a57
4 changed files with 22 additions and 12 deletions

View File

@@ -10,6 +10,14 @@ Add the `-s` option to the end of the above commands to suppress creating the `g
See [Downloads-Installs-GAM7](https://github.com/GAM-team/GAM/wiki/Downloads-Installs) for Windows or other options, including manual installation See [Downloads-Installs-GAM7](https://github.com/GAM-team/GAM/wiki/Downloads-Installs) for Windows or other options, including manual installation
### 7.35.03
Updated `gam <UserTypeEntity> print filelist|filecounts` to handle options `showsize` and `showsizeunits` as independent options.
* `showsize` - Display a column `Size` with a byte count
* `showsizeunits` - Display a column `SizeUnits` with a formatted size with units
If you select both options, you can sort multiple rows using the `Size` column.
### 7.35.02 ### 7.35.02
Added option `showsizeunits` to `gam gam <UserTypeEntity> print filelist|filecounts` as an alternative to option `showsize`. Added option `showsizeunits` to `gam gam <UserTypeEntity> print filelist|filecounts` as an alternative to option `showsize`.

View File

@@ -251,7 +251,7 @@ writes the credentials into the file oauth2.txt.
``` ```
gamteam@server:/Users/gamteam$ rm -f /Users/gamteam/GAMConfig/oauth2.txt gamteam@server:/Users/gamteam$ rm -f /Users/gamteam/GAMConfig/oauth2.txt
gamteam@server:/Users/gamteam$ gam version gamteam@server:/Users/gamteam$ gam version
GAM 7.35.02 - https://github.com/GAM-team/GAM - pyinstaller GAM 7.35.03 - https://github.com/GAM-team/GAM - pyinstaller
GAM Team <google-apps-manager@googlegroups.com> GAM Team <google-apps-manager@googlegroups.com>
Python 3.14.3 64-bit final Python 3.14.3 64-bit final
macOS Tahoe 26.3.1 arm64 macOS Tahoe 26.3.1 arm64
@@ -1034,7 +1034,7 @@ writes the credentials into the file oauth2.txt.
``` ```
C:\>del C:\GAMConfig\oauth2.txt C:\>del C:\GAMConfig\oauth2.txt
C:\>gam version C:\>gam version
GAM 7.35.02 - https://github.com/GAM-team/GAM - pythonsource GAM 7.35.03 - https://github.com/GAM-team/GAM - pythonsource
GAM Team <google-apps-manager@googlegroups.com> GAM Team <google-apps-manager@googlegroups.com>
Python 3.14.3 64-bit final Python 3.14.3 64-bit final
Windows 11 10.0.26200 AMD64 Windows 11 10.0.26200 AMD64

View File

@@ -719,7 +719,7 @@ gam <UserTypeEntity> print filecounts [todrive <ToDriveAttribute>*]
[filenamematchpattern <REMatchPattern>] [filenamematchpattern <REMatchPattern>]
<PermissionMatch>* [<PermissionMatchMode>] [<PermissionMatchAction>] <PermissionMatch>* [<PermissionMatchMode>] [<PermissionMatchAction>]
[excludetrashed] [excludetrashed]
[showsize|showsizeunits] [showmimetypesize] [showsize] [showsizeunits] [showmimetypesize]
[showlastmodification] [pathdelimiter <Character>] [showlastmodification] [pathdelimiter <Character>]
(addcsvdata <FieldName> <String>)* (addcsvdata <FieldName> <String>)*
[summary none|only|plus] [summaryuser <String>] [summary none|only|plus] [summaryuser <String>]
@@ -735,7 +735,7 @@ gam <UserTypeEntity> show filecounts
[filenamematchpattern <REMatchPattern>] [filenamematchpattern <REMatchPattern>]
<PermissionMatch>* [<PermissionMatchMode>] [<PermissionMatchAction>] <PermissionMatch>* [<PermissionMatchMode>] [<PermissionMatchAction>]
[excludetrashed] [excludetrashed]
[showsize|showsizeunits] [showmimetypesize] [showsize] [showsizeunits] [showmimetypesize]
[showlastmodification] [pathdelimiter <Character>] [showlastmodification] [pathdelimiter <Character>]
[summary none|only|plus] [summaryuser <String>] [summary none|only|plus] [summaryuser <String>]
``` ```
@@ -749,8 +749,10 @@ When `continueoninvalidquery` is true, GAM prints an error message and proceeds
as it does now. Of course, if the query really is invalid, you will get the message for every user. as it does now. Of course, if the query really is invalid, you will get the message for every user.
The `showsize` option displays the total size (in bytes) of the files counted; e.g., `31549200951`. The `showsize` option displays the total size (in bytes) of the files counted; e.g., `31549200951`.
With `print filecounts`, this will be in a column labelled `Size`.
The `showsizeunits` option displays the total size of the files counted with two decimal places and units; e.g., `31.55 GB`. The `showsizeunits` option displays the total size of the files counted with two decimal places and units; e.g., `31.55 GB`.
With `print filecounts`, this will be in a column labelled `SizeUnits`.
The `showmimetypesize` option displays the total size (in bytes) of each MIME type counted. The `showmimetypesize` option displays the total size (in bytes) of each MIME type counted.
@@ -1102,7 +1104,7 @@ gam <UserTypeEntity> print|show filelist [todrive <ToDriveAttribute>*]
[excludetrashed] [excludetrashed]
[maxfiles <Integer>] [nodataheaders <String>] [maxfiles <Integer>] [nodataheaders <String>]
[countsonly [summary none|only|plus] [summaryuser <String>] [countsonly [summary none|only|plus] [summaryuser <String>]
[showsource] [showsize|showsizeunits] [showmimetypesize]] [showsource] [showsize] [showsizeunits] [showmimetypesize]]
[countsrowfilter] [countsrowfilter]
[filepath|fullpath [folderpathonly [<Boolean>]] [pathdelimiter <Character>] [addpathstojson] [showdepth]] [buildtree] [filepath|fullpath [folderpathonly [<Boolean>]] [pathdelimiter <Character>] [addpathstojson] [showdepth]] [buildtree]
[allfields|<DriveFieldName>*|(fields <DriveFieldNameList>)] [allfields|<DriveFieldName>*|(fields <DriveFieldNameList>)]
@@ -1308,7 +1310,7 @@ The `countsonly` suboption `showsource` adds additional columns `Source` and `Na
The `countsonly` suboption `showsize` adds an additional column `Size` that indicates the total size (in bytes) of the files represented on the row; e.g., `31549200951`. The `countsonly` suboption `showsize` adds an additional column `Size` that indicates the total size (in bytes) of the files represented on the row; e.g., `31549200951`.
The `countsonly` suboption `showsizeunits` adds an additional column `Size` that indicates the total size of the files represented on the row with two decimal places and units; e.g., `31.55 GB`. The `countsonly` suboption `showsizeunits` adds an additional column `SizeUnits` that indicates the total size of the files represented on the row with two decimal places and units; e.g., `31.55 GB`.
The `countsonly` suboption `showmimetypesize` adds additional columns `<MimeType>:Size` that indicate the total size (in bytes) of each MIME type. The `countsonly` suboption `showmimetypesize` adds additional columns `<MimeType>:Size` that indicate the total size (in bytes) of each MIME type.

View File

@@ -3,7 +3,7 @@
Print the current version of Gam with details Print the current version of Gam with details
``` ```
gam version gam version
GAM 7.35.02 - https://github.com/GAM-team/GAM - pyinstaller GAM 7.35.03 - https://github.com/GAM-team/GAM - pyinstaller
GAM Team <google-apps-manager@googlegroups.com> GAM Team <google-apps-manager@googlegroups.com>
Python 3.14.3 64-bit final Python 3.14.3 64-bit final
macOS Tahoe 26.3.1 arm64 macOS Tahoe 26.3.1 arm64
@@ -15,7 +15,7 @@ Time: 2026-02-15T07:51:00-08:00
Print the current version of Gam with details and time offset information Print the current version of Gam with details and time offset information
``` ```
gam version timeoffset gam version timeoffset
GAM 7.35.02 - https://github.com/GAM-team/GAM - pyinstaller GAM 7.35.03 - https://github.com/GAM-team/GAM - pyinstaller
GAM Team <google-apps-manager@googlegroups.com> GAM Team <google-apps-manager@googlegroups.com>
Python 3.14.3 64-bit final Python 3.14.3 64-bit final
macOS Tahoe 26.3.1 arm64 macOS Tahoe 26.3.1 arm64
@@ -27,7 +27,7 @@ Your system time differs from www.googleapis.com by less than 1 second
Print the current version of Gam with extended details and SSL information Print the current version of Gam with extended details and SSL information
``` ```
gam version extended gam version extended
GAM 7.35.02 - https://github.com/GAM-team/GAM - pyinstaller GAM 7.35.03 - https://github.com/GAM-team/GAM - pyinstaller
GAM Team <google-apps-manager@googlegroups.com> GAM Team <google-apps-manager@googlegroups.com>
Python 3.14.3 64-bit final Python 3.14.3 64-bit final
macOS Tahoe 26.3.1 arm64 macOS Tahoe 26.3.1 arm64
@@ -68,7 +68,7 @@ MacOS High Sierra 10.13.6 x86_64
Path: /Users/gamteam/bin/gam7 Path: /Users/gamteam/bin/gam7
Version Check: Version Check:
Current: 5.35.08 Current: 5.35.08
Latest: 7.35.02 Latest: 7.35.03
echo $? echo $?
1 1
``` ```
@@ -76,7 +76,7 @@ echo $?
Print the current version number without details Print the current version number without details
``` ```
gam version simple gam version simple
7.35.02 7.35.03
``` ```
In Linux/MacOS you can do: In Linux/MacOS you can do:
``` ```
@@ -86,7 +86,7 @@ echo $VER
Print the current version of Gam and address of this Wiki Print the current version of Gam and address of this Wiki
``` ```
gam help gam help
GAM 7.35.02 - https://github.com/GAM-team/GAM GAM 7.35.03 - https://github.com/GAM-team/GAM
GAM Team <google-apps-manager@googlegroups.com> GAM Team <google-apps-manager@googlegroups.com>
Python 3.14.3 64-bit final Python 3.14.3 64-bit final
macOS Tahoe 26.3.1 arm64 macOS Tahoe 26.3.1 arm64