12345678910111213141516171819202122232425262728 |
- // #!/bin/bash
- // #/ Usage: script/update-dependencies
- // #/ Create a branch to update a dependency.
- // # Delete update-dependencies branch if it exists
- // if git branch | grep -q "update-dependencies"; then
- // echo "Deleting update-dependencies branch 🗑"
- // git branch -D update-dependencies
- // echo "Branch deleted 🎉"
- // fi
- // # Create update-dependencies branch
- // echo "Creating update-dependencies branch 🌱"
- // git checkout -b update-dependencies
- // echo "Branch created 🎉"
- // # Update dependencies in package.json
- // echo "Updating dependencies in package.json 📦"
- // pnpm update --interactive --recursive --latest
- // # Clean up pnpm-lock.yaml file and install dependencies
- // script/clean && pnpm install
- // # Git operations
- // git add -A
- // git commit -am "chore: update dependencies 📦"
- // git push origin update-dependencies
- // gh pr create --fill
- // echo "Dependencies updated 🎉"
|