From fe223e64f6f5ef47caf2a07237d5aef56b25edd2 Mon Sep 17 00:00:00 2001 From: "Salvador E. Tropea" Date: Fri, 30 Sep 2022 12:39:28 -0300 Subject: [PATCH] [DOCs] Added note about `checkout` GitHub action - It produces a shallow checkout Related to #308 --- README.md | 4 +++- docs/samples/generic_plot.kibot.yaml | 6 ++++-- kibot/out_diff.py | 6 ++++-- 3 files changed, 11 insertions(+), 5 deletions(-) diff --git a/README.md b/README.md index 3955bd4a..c726ac1e 100644 --- a/README.md +++ b/README.md @@ -1698,7 +1698,7 @@ Notes: read https://stackoverflow.com/questions/1248029/git-pull-error-entry-foo-not-uptodate-cannot-merge. - `fuzz`: [number=5] [0,100] Color tolerance (fuzzyness) for the `stats` mode. - `new`: [string|list(string)] The file you want to compare. Leave it blank for the current PCB/SCH. - A list is accepted only for the `multivar` type. + A list is accepted only for the `multivar` type. Consult the `old` option for more information. - `new_type`: [string='current'] [git,file,output,multivar,current] How to interpret the `new` name. Use `git` for a git hash, branch, etc. Use `current` for the currently loaded PCB/Schematic. Use `file` for a file name. Use `output` to specify the name of a `pcb_variant`/`sch_variant` output. @@ -1710,6 +1710,8 @@ Notes: reference to the changes in the PCB/SCH. The `n` value is how many changes in the history you want to go back. A 0 is the same as `HEAD`, a 1 means the last time the PCB/SCH was changed, etc. + Important: when using the `checkout` GitHub action you just get the + last commit. To clone the full repo use `fetch-depth: '0'`. - `old_type`: [string='git'] [git,file,output,multivar] How to interpret the `old` name. Use `git` for a git hash, branch, etc. Use `file` for a file name. Use `output` to specify the name of a `pcb_variant`/`sch_variant` output. Use `multivar` to specify a reference file when `new_type` is also `multivar`. diff --git a/docs/samples/generic_plot.kibot.yaml b/docs/samples/generic_plot.kibot.yaml index f9445757..eb26c4d8 100644 --- a/docs/samples/generic_plot.kibot.yaml +++ b/docs/samples/generic_plot.kibot.yaml @@ -496,7 +496,7 @@ outputs: # [number=5] [0,100] Color tolerance (fuzzyness) for the `stats` mode fuzz: 5 # [string|list(string)] The file you want to compare. Leave it blank for the current PCB/SCH. - # A list is accepted only for the `multivar` type + # A list is accepted only for the `multivar` type. Consult the `old` option for more information new: '' # [string='current'] [git,file,output,multivar,current] How to interpret the `new` name. Use `git` for a git hash, branch, etc. # Use `current` for the currently loaded PCB/Schematic. @@ -509,7 +509,9 @@ outputs: # As `HEAD` is for the whole repo you can use `KIBOT_LAST-n` to make # reference to the changes in the PCB/SCH. The `n` value is how many # changes in the history you want to go back. A 0 is the same as `HEAD`, - # a 1 means the last time the PCB/SCH was changed, etc + # a 1 means the last time the PCB/SCH was changed, etc. + # Important: when using the `checkout` GitHub action you just get the + # last commit. To clone the full repo use `fetch-depth: '0'` old: 'HEAD' # [string='git'] [git,file,output,multivar] How to interpret the `old` name. Use `git` for a git hash, branch, etc. # Use `file` for a file name. Use `output` to specify the name of a `pcb_variant`/`sch_variant` output. diff --git a/kibot/out_diff.py b/kibot/out_diff.py index 89a0fa34..eb4e0265 100644 --- a/kibot/out_diff.py +++ b/kibot/out_diff.py @@ -54,14 +54,16 @@ class DiffOptions(BaseOptions): As `HEAD` is for the whole repo you can use `KIBOT_LAST-n` to make reference to the changes in the PCB/SCH. The `n` value is how many changes in the history you want to go back. A 0 is the same as `HEAD`, - a 1 means the last time the PCB/SCH was changed, etc """ + a 1 means the last time the PCB/SCH was changed, etc. + Important: when using the `checkout` GitHub action you just get the + last commit. To clone the full repo use `fetch-depth: '0'` """ self.old_type = 'git' """ [git,file,output,multivar] How to interpret the `old` name. Use `git` for a git hash, branch, etc. Use `file` for a file name. Use `output` to specify the name of a `pcb_variant`/`sch_variant` output. Use `multivar` to specify a reference file when `new_type` is also `multivar` """ self.new = '' """ [string|list(string)] The file you want to compare. Leave it blank for the current PCB/SCH. - A list is accepted only for the `multivar` type """ + A list is accepted only for the `multivar` type. Consult the `old` option for more information """ self.new_type = 'current' """ [git,file,output,multivar,current] How to interpret the `new` name. Use `git` for a git hash, branch, etc. Use `current` for the currently loaded PCB/Schematic.