Browse Source

Bump version and updated publish script

Remove extra name setting because we renamed the GitHub username anyway.
master
TheoryOfNekomata 4 years ago
parent
commit
ce9b5b1deb
3 changed files with 6 additions and 13 deletions
  1. +1
    -2
      README.md
  2. +1
    -3
      package.json
  3. +4
    -8
      publish.sh

+ 1
- 2
README.md View File

@@ -133,8 +133,7 @@ const NaturalKey = ({
export default NaturalKey
```

Take note that pressed keys from multiple channels might overlap, therefore it is advisable to support multiple channels
pressing a single key at once.
Take note that pressed keys from multiple channels might overlap, therefore it is advisable to support multiple channels pressing a single key at once.

## License



+ 1
- 3
package.json View File

@@ -1,5 +1,5 @@
{
"version": "1.0.11",
"version": "1.0.12",
"license": "MIT",
"main": "dist/index.js",
"typings": "dist/index.d.ts",
@@ -11,14 +11,12 @@
"private": false,
"publishing": {
"github": {
"name": "@temoto-kun/react-musical-keyboard",
"repository": "https://github.com/Temoto-kun/react-musical-keyboard.git",
"publishConfig": {
"registry": "https://npm.pkg.github.com"
}
},
"master": {
"name": "@theoryofnekomata/react-musical-keyboard",
"repository": "https://code.modal.sh/TheoryOfNekomata/react-musical-keyboard.git",
"publishConfig": {
"registry": "https://js.pack.modal.sh"


+ 4
- 8
publish.sh View File

@@ -1,24 +1,20 @@
defaultBranch=master

for branch in $(cat package.json | jq .publishing | jq -r keys[]) ; do
echo "Selected configuration: $branch"

rawRepository=$(cat package.json | jq -r .publishing.$branch.repository)
repository=$(cat package.json | jq -r .publishing.$branch.repository)
defaultRepository=$(cat package.json | jq -r .publishing.$defaultBranch.repository)

if [ $repository = $defaultRepository ]; then
echo "Changing to default repository: $repository"
echo "$( jq --arg repository "$repository" '.repository = $repository' package.json )" > package.json
echo "Publishing to primary repository: $repository"
elif [ $rawRepository != 'null' ]; then
echo "$branch is a mirror"
echo "Changing to mirror repository: $repository"
echo "$( jq --arg repository "$repository" '.repository = $repository' package.json )" > package.json
echo "Publishing to mirror repository: $repository"
fi

rawName=$(cat package.json | jq .publishing.$branch.name)
if [ $rawName != 'null' ]; then
name=$(cat package.json | jq -r .publishing.$branch.name)
echo "$( jq --arg name "$name" '.name = $name' package.json )" > package.json
fi
registry=$(cat package.json | jq -r .publishing.$branch.publishConfig.registry)
echo "Publishing to package repository: $registry"
npm publish --registry=$registry --access public


Loading…
Cancel
Save