Add patag alias
This commit is contained in:
parent
048804048f
commit
2b47bfba47
3 changed files with 13 additions and 5 deletions
|
|
@ -1,7 +1,8 @@
|
||||||
{
|
{
|
||||||
"permissions": {
|
"permissions": {
|
||||||
"allow": [
|
"allow": [
|
||||||
"Bash(git:*)"
|
"Bash(git:*)",
|
||||||
|
"Bash(exec zsh)"
|
||||||
],
|
],
|
||||||
"deny": []
|
"deny": []
|
||||||
}
|
}
|
||||||
|
|
|
||||||
5
CLAUDE.md
Normal file
5
CLAUDE.md
Normal file
|
|
@ -0,0 +1,5 @@
|
||||||
|
## Nix Configuration System
|
||||||
|
|
||||||
|
- This is my nix configuration system. Whenever you need to introduce update to my config, remember to check the current config.
|
||||||
|
- When you are going to introduce update to my nix config, do it on a experimental branch (use 'nightly'), and commit to that branch after you perform test to check the updates work as intended. Never work on the master branch which I will perform merge manually.
|
||||||
|
- After you introduce updates, remember to reflect those updates in the readme, should they bring any changes.
|
||||||
|
|
@ -115,16 +115,18 @@
|
||||||
local tags_string="$1"
|
local tags_string="$1"
|
||||||
local query="$2"
|
local query="$2"
|
||||||
|
|
||||||
# Split tags by # and build --add arguments
|
# Build --add arguments by processing each tag
|
||||||
local add_args=""
|
local add_args=""
|
||||||
IFS='#' read -ra tags <<< "$tags_string"
|
local oldIFS="$IFS"
|
||||||
for tag in "${tags[@]}"; do
|
IFS='#'
|
||||||
# Trim whitespace and add to arguments
|
for tag in $tags_string; do
|
||||||
|
# Trim whitespace
|
||||||
tag=$(echo "$tag" | xargs)
|
tag=$(echo "$tag" | xargs)
|
||||||
if [ -n "$tag" ]; then
|
if [ -n "$tag" ]; then
|
||||||
add_args="$add_args --add \"$tag\""
|
add_args="$add_args --add \"$tag\""
|
||||||
fi
|
fi
|
||||||
done
|
done
|
||||||
|
IFS="$oldIFS"
|
||||||
|
|
||||||
# Execute the papis tag command
|
# Execute the papis tag command
|
||||||
eval "papis tag $add_args \"$query\""
|
eval "papis tag $add_args \"$query\""
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue