Musical keyboard component written in React.
25개 이상의 토픽을 선택하실 수 없습니다. Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
 
 
 
 

31 lines
1.2 KiB

  1. defaultBranch=master
  2. for branch in $(cat package.json | jq .publishing | jq -r keys[]) ; do
  3. git checkout $branch
  4. rawRepository=$(cat package.json | jq -r .publishing.$branch.repository)
  5. repository=$(cat package.json | jq -r .publishing.$branch.repository)
  6. defaultRepository=$(cat package.json | jq -r .publishing.$defaultBranch.repository)
  7. if [ $repository = $defaultRepository ]; then
  8. echo "$( jq --arg repository "$repository" '.repository = $repository' package.json )" > package.json
  9. echo "Publishing to primary repository: $repository"
  10. git push
  11. elif [ $rawRepository != 'null' ]; then
  12. echo "$branch is a mirror"
  13. echo "$( jq --arg repository "$repository" '.repository = $repository' package.json )" > package.json
  14. echo "Publishing to mirror repository: $repository"
  15. git commit -am "Publish to $branch"
  16. git push --mirror $repository
  17. fi
  18. rawName=$(cat package.json | jq .publishing.$branch.name)
  19. if [ $rawName != 'null' ]; then
  20. name=$(cat package.json | jq -r .publishing.$branch.name)
  21. echo "$( jq --arg name "$name" '.name = $name' package.json )" > package.json
  22. fi
  23. registry=$(cat package.json | jq -r .publishing.$branch.publishConfig.registry)
  24. echo $registry
  25. npm publish --registry=$registry
  26. done