-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
scripts: added scripts to automatically update shared package files d…
…uring deployment; Fixed links to images in README;
- Loading branch information
Showing
23 changed files
with
126 additions
and
75 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
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -27,3 +27,5 @@ dist-ssr | |
tests-report | ||
# Local Netlify folder | ||
.netlify | ||
|
||
*-e |
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
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
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
Binary file not shown.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file not shown.
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 |
---|---|---|
@@ -0,0 +1 @@ | ||
{"name":"","short_name":"","icons":[{"src":"/android-chrome-192x192.png","sizes":"192x192","type":"image/png"},{"src":"/android-chrome-512x512.png","sizes":"512x512","type":"image/png"}],"theme_color":"#ffffff","background_color":"#ffffff","display":"standalone"} |
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
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
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
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 |
---|---|---|
@@ -0,0 +1,50 @@ | ||
#!/bin/bash | ||
|
||
ICON=resize-bounding.svg | ||
PREVIEW=resize-bounding.gif | ||
README=README.md | ||
IMAGES_PATH=images | ||
LIB_PATH=packages/vue3-resize-bounding | ||
DEMO_PATH=demo | ||
DEMO_PUBLIC_PATH=$DEMO_PATH/public | ||
|
||
MONOREPO_PACKAGE_JSON=package.json | ||
DEMO_PACKAGE_JSON=$DEMO_PATH/package.json | ||
LIB_PACKAGE_JSON=$LIB_PATH/package.json | ||
|
||
MONOREPO_LICENSE=LICENSE | ||
LIB_LICENSE=$LIB_PATH/LICENSE | ||
|
||
VERSION_PATTERN="[[:digit:]][[:graph:]][[:digit:]][[:graph:]][[:digit:]]" | ||
|
||
function get_version { | ||
VERSION=$(grep version $1 | sed "s/.*\"version\": \"\($VERSION_PATTERN\)\".*/\1/") | ||
} | ||
|
||
function change_readme_version () { | ||
sed -i -e "s/version-$VERSION_PATTERN-blue/version-$1-blue/g" $2 | ||
sed -i -e "s@/v$VERSION_PATTERN@/v$1@g" $2 | ||
} | ||
|
||
function change_pkg_version { | ||
sed -i -e "s@\(.*\"$1\"\): \"\(.*\)\"@\1: ""\"$VERSION\"@" $2 | ||
} | ||
|
||
get_version $MONOREPO_PACKAGE_JSON | ||
|
||
# update LICENSE: | ||
cp $MONOREPO_LICENSE $LIB_LICENSE | ||
|
||
# copy assets: | ||
cp $IMAGES_PATH/$ICON $LIB_PATH | ||
cp $IMAGES_PATH/$ICON $DEMO_PUBLIC_PATH | ||
cp $IMAGES_PATH/$PREVIEW $LIB_PATH | ||
cp $IMAGES_PATH/$PREVIEW $DEMO_PUBLIC_PATH | ||
|
||
# change and copy README: | ||
change_readme_version $VERSION $README | ||
cp $README $LIB_PATH/$README | ||
|
||
# change PKG files: | ||
change_pkg_version productVersion $DEMO_PACKAGE_JSON | ||
change_pkg_version version $LIB_PACKAGE_JSON |