Commit graph

11 commits

Author SHA1 Message Date
Joey Riches
792b0d78d4 common/Scripts: Allow no args usage of cpesearch()
**Summary**
- When no args are passed to cpesearch() it'll use the current
  directory name. Useful in combination with gotopkg().
2024-02-29 17:52:57 +00:00
Rune Morling
f501790397
helpers*sh: Update/add cpesearch for bash/fish/zsh
Now supports showing usage if '-h' and '--help' are supplied as arguments

Signed-off-by: Rune Morling <ermo@serpentos.com>
2024-01-31 21:31:03 +01:00
Rune Morling
924ad56611
cpesearch: Rename from cvefuzzysearch per request
**Summary**

Signed-off-by: Rune Morling <ermo@serpentos.com>
2024-01-31 20:19:26 +01:00
Rune Morling
1593c59ba7
helpers*sh: Add a primitive cvefuzzysearch function
This can be useful when looking up the correct CPE $PRODUCT:$VENDOR pair
for monitoring.yml purpurses and for manually searching for known CVEs.

This commit only adds a PoC bash script helper.

Signed-off-by: Rune Morling <ermo@serpentos.com>
2024-01-30 17:47:59 +01:00
Rune Morling
eb18e1b921
helpers.*sh: Rename function to localrepo_reindex
This fixes an issue where lightdm-wrapper would choke on the previous
function name (reindex-localrepo) when logging into Budgie.

Reported and tested working by @yusi1.

Signed-off-by: Rune Morling <ermo@serpentos.com>
2024-01-22 02:24:31 +01:00
Rune Morling
32b4caeafd
helpers.*sh: Add reindex-localrepo convenience function
**Summary**
We have no convenient way to re-index our local repo.

Since it is quite a long command, why not add a convenience function to
do it correctly that is maintained by Solus Staff?

This commit does just that for all helper scripts.

Signed-off-by: Rune Morling <ermo@serpentos.com>
2024-01-20 18:56:19 +01:00
Joey Riches
f3c9ab8905 common/Scripts: return 1 instead of exit 1 on err in helper.sh
So it doesn't exit the shell.
2023-12-13 18:42:45 +00:00
Rune Morling
68406a8c42
common/Scripts/helpers.sh: Document bash completion
A little is better than nothing?

Signed-off-by: Rune Morling <ermo@serpentos.com>
2023-12-05 01:08:27 +01:00
Silke Hofstra
20abd1fa3f common: shellcheck Bash helper script 2023-12-04 23:10:46 +01:00
Joey Riches
de3ba6f9fb common/Scripts: replace annoying pushd usage with cd in helpers.sh
To match .fish and .zsh helpers. Plus, it was annoying having massive
pushd stacks.
2023-10-20 12:27:14 +01:00
Joey Riches
c6793325d1 common: Initial helpers script to provide common functionality 2023-09-30 17:37:53 +01:00