31.nuget-push.sh 597 B

1234567891011121314151617181920212223242526272829303132333435
  1. set -e
  2. #---------------------------------------------------------------------
  3. #(x.1)参数
  4. args_="
  5. export codePath=/root/temp/svn
  6. export NUGET_SERVER=https://api.nuget.org/v3/index.json
  7. export NUGET_KEY=xxxxxxxxxx
  8. # "
  9. nugetPath=Publish/release/release/nuget
  10. #----------------------------------------------
  11. echo "(x.2)nuget-push"
  12. docker run -i --rm \
  13. --env LANG=C.UTF-8 \
  14. -v $codePath:/root/code \
  15. serset/dotnet:6.0-sdk \
  16. bash -c "
  17. for file in /root/code/$nugetPath/*.nupkg
  18. do
  19. echo nuget push \$file
  20. #dotnet nuget push \$file -k ${NUGET_KEY} -s ${NUGET_SERVER}
  21. done
  22. " || true