mirror of
https://github.com/unmojang/meta.git
synced 2025-09-24 03:31:03 -04:00
Make meta self-contained
Relevant git and s3 configs and secrets are now taken from a `config` folder.
This commit is contained in:
parent
ad98ec2d6c
commit
b1113057ad
1
.gitignore
vendored
1
.gitignore
vendored
@ -3,3 +3,4 @@ multimc
|
||||
upstream
|
||||
__pycache__
|
||||
*.kdev4
|
||||
config_local.sh
|
3
config/.gitignore
vendored
Normal file
3
config/.gitignore
vendored
Normal file
@ -0,0 +1,3 @@
|
||||
*.key
|
||||
*.pub
|
||||
s3cmd.cfg
|
5
config/config_local.sh.example
Normal file
5
config/config_local.sh.example
Normal file
@ -0,0 +1,5 @@
|
||||
export MODE=master
|
||||
export GIT_AUTHOR_NAME="Petr Mrázek"
|
||||
export GIT_AUTHOR_EMAIL="peterix@gmail.com"
|
||||
export GIT_COMMITTER_NAME="$GIT_AUTHOR_NAME"
|
||||
export GIT_COMMITTER_EMAIL="$GIT_AUTHOR_EMAIL"
|
8
config/readme.txt
Normal file
8
config/readme.txt
Normal file
@ -0,0 +1,8 @@
|
||||
This is where you should put the git deploy keys.
|
||||
|
||||
These are expected:
|
||||
* meta-multimc.key
|
||||
* meta-multimc.key.pub
|
||||
* meta-upstream.key
|
||||
* meta-upstream.key.pub
|
||||
* s3cmd.cfg
|
10
update.sh
10
update.sh
@ -7,8 +7,8 @@ BASEDIR=`pwd`
|
||||
set -x
|
||||
|
||||
source config.sh
|
||||
if [ -f config_local.sh ]; then
|
||||
source config_local.sh
|
||||
if [ -f config/config_local.sh ]; then
|
||||
source config/config_local.sh
|
||||
fi
|
||||
|
||||
MODE=${MODE:-develop}
|
||||
@ -46,7 +46,7 @@ cd "${BASEDIR}/${UPSTREAM_DIR}"
|
||||
git add mojang/version_manifest.json mojang/versions/* mojang/assets/* forge/*.json liteloader/*.json || fail_in
|
||||
if ! git diff --cached --exit-code ; then
|
||||
git commit -a -m "Update ${currentDate}" || fail_in
|
||||
git push || exit 1
|
||||
GIT_SSH_COMMAND="ssh -i ${BASEDIR}/config/meta-upstream.key" git push || exit 1
|
||||
fi
|
||||
cd "${BASEDIR}"
|
||||
|
||||
@ -64,10 +64,10 @@ cd "${BASEDIR}/${MMC_DIR}"
|
||||
git add index.json org.lwjgl/* net.minecraft/* net.minecraftforge/* com.mumfrey.liteloader/* || fail_out
|
||||
if ! git diff --cached --exit-code ; then
|
||||
git commit -a -m "Update ${currentDate}" || fail_out
|
||||
git push || exit 1
|
||||
GIT_SSH_COMMAND="ssh -i ${BASEDIR}/config/meta-multimc.key" git push || exit 1
|
||||
fi
|
||||
cd "${BASEDIR}"
|
||||
|
||||
s3cmd --exclude=".git*" --delete-removed sync ${BASEDIR}/${MMC_DIR}/ ${S3_BUCKET} || exit 2
|
||||
s3cmd -c ${BASEDIR}/config/s3cmd.cfg --exclude=".git*" --delete-removed sync ${BASEDIR}/${MMC_DIR}/ ${S3_BUCKET} || exit 2
|
||||
|
||||
exit 0
|
||||
|
Loading…
x
Reference in New Issue
Block a user