chore: add packaging script

This commit is contained in:
Anna 2020-09-04 14:02:34 -04:00
parent 62dc9ce987
commit 828aa6914f
Signed by: anna
GPG Key ID: 0B391D8F06FCD9E0
3 changed files with 33 additions and 0 deletions

3
.gitignore vendored
View File

@ -3,6 +3,9 @@
##
## Get latest from https://github.com/github/gitignore/blob/master/VisualStudio.gitignore
# Packaging
pack/
# User-specific files
*.rsuser
*.suo

View File

@ -83,6 +83,7 @@
<ItemGroup>
<None Include="definitions.yaml" />
<None Include="NoSoliciting.json" />
<None Include="package.sh" />
<None Include="packages.config" />
</ItemGroup>
<ItemGroup>

29
NoSoliciting/package.sh Normal file
View File

@ -0,0 +1,29 @@
#!/bin/sh
# remove old pack dir
rm -rf pack
# make temp dir and go to it
mkdir -p pack/temp
cd pack/temp || exit
# copy the dlls, defs, and the manifest
cp ../../bin/Release/NoSoliciting.dll ../../bin/Release/YamlDotNet.dll ./
cp ../../definitions.yaml default_definitions.yaml
cp ../../NoSoliciting.json ./
# make sure none of them are marked executable
chmod -x ./*
# zip them
zip ../latest.zip ./*
# move the manifest next to the zip
mv NoSoliciting.json ../
# remove everything
rm ./*
# go back up and remove the temp dir
cd ..
rmdir temp