blog/.devcontainer/post-create.sh
Radu C. Martin 02a5993d1c
Some checks failed
Build and publish docker image / build-site (push) Successful in 2m23s
Build and publish docker image / build-docker (push) Failing after 1m0s
feat: initial commit
2025-04-04 22:43:11 +02:00

18 lines
631 B
Bash

#!/usr/bin/env bash
if [ -f package.json ]; then
bash -i -c "nvm install --lts && nvm install-latest-npm"
npm i
npm run build
fi
# Install dependencies for shfmt extension
curl -sS https://webi.sh/shfmt | sh &>/dev/null
# Add OMZ plugins
git clone https://github.com/zsh-users/zsh-syntax-highlighting.git ~/.oh-my-zsh/custom/plugins/zsh-syntax-highlighting
git clone https://github.com/zsh-users/zsh-autosuggestions ~/.oh-my-zsh/custom/plugins/zsh-autosuggestions
sed -i -E "s/^(plugins=\()(git)(\))/\1\2 zsh-syntax-highlighting zsh-autosuggestions\3/" ~/.zshrc
# Avoid git log use less
echo -e "\nunset LESS" >>~/.zshrc