publishD.cmd 599 B

123456789101112131415161718192021222324252627282930
  1. @echo off
  2. set nuget=D:\Projects\nuget.exe
  3. rem ** check if directories exists **
  4. if not exist "bin" goto err_bin_not_found
  5. if not exists %LOCAL_NUGET_REPO% goto err_locnuget_not_found
  6. rem ** cleanup **
  7. rmdir /s /q bin\debug
  8. %nuget%
  9. rem ** build **
  10. dotnet pack -c Debug
  11. for %i in (bin\debug) do nuget
  12. goto done
  13. :err_bin_not_found
  14. echo ERR: missing 'bin' directory in current location
  15. goto exit
  16. :err_locnuget_not_found
  17. echo ERR: cannot access directory stored in enviromental variable 'LOCAL_NUGET_REPO' or path is invalid.
  18. goto exit
  19. :done
  20. echo *** DONE ***
  21. :exit