diff --git a/.ddev/addon-metadata/pimp-my-shell/manifest.yaml b/.ddev/addon-metadata/pimp-my-shell/manifest.yaml index d8be1e6..671857c 100644 --- a/.ddev/addon-metadata/pimp-my-shell/manifest.yaml +++ b/.ddev/addon-metadata/pimp-my-shell/manifest.yaml @@ -1,7 +1,7 @@ name: pimp-my-shell repository: . version: "" -install_date: "2024-04-06T19:16:47-03:00" +install_date: "2024-04-09T17:47:01-03:00" project_files: - web-build/Dockerfile.pimp-my-shell - homeadditions/.bashrc.d/pimp-my-shell.sh @@ -13,7 +13,6 @@ project_files: - homeadditions/.local/share/fish/vendor_completions.d/ahoy.fish - homeadditions/.config/starship.toml - homeadditions/.config/fish/conf.d/pimp-my-shell.fish - - homeadditions/.config/fish/conf.d/z.fish - pimp-my-shell/hooks/README.md - pimp-my-shell/hooks/post-import-db.sh - pimp-my-shell/hooks/post-import-db.d diff --git a/.ddev/homeadditions/.config/fish/conf.d/pimp-my-shell.fish b/.ddev/homeadditions/.config/fish/conf.d/pimp-my-shell.fish index 1883878..d98ce59 100644 --- a/.ddev/homeadditions/.config/fish/conf.d/pimp-my-shell.fish +++ b/.ddev/homeadditions/.config/fish/conf.d/pimp-my-shell.fish @@ -1,4 +1,10 @@ #ddev-generated + +# z.lua +mkdir -p /mnt/ddev-global-cache/z.lua/$HOSTNAME +set -x _ZL_DATA /mnt/ddev-global-cache/z.lua/$HOSTNAME/.zlua +lua /opt/z.lua/z.lua --init fish | source + function fish_title echo "$DDEV_PROJECT ddev@"(fish_prompt_pwd_dir_length=1 prompt_pwd) - $argv end diff --git a/.ddev/homeadditions/.config/fish/conf.d/z.fish b/.ddev/homeadditions/.config/fish/conf.d/z.fish deleted file mode 100644 index f6a757c..0000000 --- a/.ddev/homeadditions/.config/fish/conf.d/z.fish +++ /dev/null @@ -1,3 +0,0 @@ -#ddev-generated - -lua /opt/z.lua/z.lua --init fish | source diff --git a/homeadditions/.config/fish/conf.d/pimp-my-shell.fish b/homeadditions/.config/fish/conf.d/pimp-my-shell.fish index 1883878..d98ce59 100644 --- a/homeadditions/.config/fish/conf.d/pimp-my-shell.fish +++ b/homeadditions/.config/fish/conf.d/pimp-my-shell.fish @@ -1,4 +1,10 @@ #ddev-generated + +# z.lua +mkdir -p /mnt/ddev-global-cache/z.lua/$HOSTNAME +set -x _ZL_DATA /mnt/ddev-global-cache/z.lua/$HOSTNAME/.zlua +lua /opt/z.lua/z.lua --init fish | source + function fish_title echo "$DDEV_PROJECT ddev@"(fish_prompt_pwd_dir_length=1 prompt_pwd) - $argv end diff --git a/homeadditions/.config/fish/conf.d/z.fish b/homeadditions/.config/fish/conf.d/z.fish deleted file mode 100644 index f6a757c..0000000 --- a/homeadditions/.config/fish/conf.d/z.fish +++ /dev/null @@ -1,3 +0,0 @@ -#ddev-generated - -lua /opt/z.lua/z.lua --init fish | source diff --git a/install.yaml b/install.yaml index ec790ce..c203ab0 100644 --- a/install.yaml +++ b/install.yaml @@ -10,8 +10,18 @@ project_files: - homeadditions/.local/share/fish/vendor_completions.d/ahoy.fish - homeadditions/.config/starship.toml - homeadditions/.config/fish/conf.d/pimp-my-shell.fish - - homeadditions/.config/fish/conf.d/z.fish - pimp-my-shell/hooks/README.md - pimp-my-shell/hooks/post-import-db.sh - pimp-my-shell/hooks/post-import-db.d - pimp-my-shell/scripts/drush-uli.sh +post_install_actions: + - | + #ddev-description: Remove deprecated z.fish file + remove_file="homeadditions/.config/fish/conf.d/z.fish" + if [ -f "$remove_file" ]; then + if grep '#ddev-generated' "$remove_file"; then + rm "$remove_file" + else + echo "Existing "$remove_file" does not have #ddev-generated, so can't be removed" + fi + fi