-
Notifications
You must be signed in to change notification settings - Fork 29
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
* add megavault texts * Update app.ts * add generate to bump version script * add new script for PRs * bump to 1.1.199 * unique-ify the string key --------- Co-authored-by: Mike <[email protected]>
- Loading branch information
Showing
5 changed files
with
36 additions
and
7 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,15 +1,35 @@ | ||
#!/bin/sh | ||
|
||
# search for the first line that starts with "version" in package.json | ||
# get the value in the quotes | ||
# Parse the boolean parameter | ||
SHOW_IMPORTANT_TEXT=true | ||
if [ "$1" = "--no-warning" ]; then | ||
SHOW_IMPORTANT_TEXT=false | ||
fi | ||
|
||
# Search for the first line that starts with "version" in package.json | ||
# Get the value in the quotes | ||
VERSION=$(cat package.json | jq -r '.version') | ||
|
||
echo "Current version is $VERSION. Enter new version (or press enter to skip):" | ||
read NEW_VERSION | ||
|
||
#if NEW_VERSION is not empty, replace the version in package.json | ||
# If NEW_VERSION is not empty, replace the version in package.json | ||
if [ -n "$NEW_VERSION" ]; then | ||
sed -i '' "s/ \"version\": \"$VERSION\"/ \"version\": \"$NEW_VERSION\"/" package.json | ||
echo "Version bumped to $NEW_VERSION" | ||
npm i | ||
fi | ||
|
||
# ANSI color code for red | ||
RED='\033[0;31m' | ||
# ANSI color code for resetting color | ||
NC='\033[0m' | ||
|
||
# Display the important text only if SHOW_IMPORTANT_TEXT is true | ||
if [ "$SHOW_IMPORTANT_TEXT" = true ]; then | ||
echo "" | ||
echo "${RED}**************************************************************" | ||
echo "* IMPORTANT: If you are creating a PR, run \`npm run prepare_for_pr\` *" | ||
echo "**************************************************************${NC}" | ||
echo "" | ||
fi |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters