diff --git a/.autogen/autogen.sh b/.autogen/autogen.sh index 1ea71ff00..f01f63327 100755 --- a/.autogen/autogen.sh +++ b/.autogen/autogen.sh @@ -1,18 +1,19 @@ #!/usr/bin/env bash -# BEARER_TOKEN= -# CAMPAIGN_ID= -# GITHUB_TOKEN= -# HEAD='acid-chicken:patch-autogen' -# REPO='syuilo/misskey' -test "$(curl -LSs -w '\n' -- "https://api.github.com/repos/$REPO/pulls?access_token=$GITHUB_TOKEN" | jq -r '.[].head.label' | grep $HEAD)" && exit 1 +# __MISSKEY_BEARER_TOKEN= +# __MISSKEY_CAMPAIGN_ID= +# __MISSKEY_GITHUB_TOKEN= +# __MISSKEY_HEAD=acid-chicken:patch-autogen +# __MISSKEY_REPO=syuilo/misskey +# __MISSKEY_BRANCH=develop +test "$(curl -LSs -w '\n' -- "https://api.github.com/repos/$REPO/pulls?access_token=$__MISSKEY_GITHUB_TOKEN" | jq -r '.[].head.label' | grep $__MISSKEY_HEAD)" && exit 1 cd "$(dirname $0)/.." && \ touch null.cache && \ rm *.cache && \ -git checkout master && \ -git pull origin master && \ -git pull upstream master && \ +git checkout $__MISSKEY_BRANCH && \ +git pull origin $__MISSKEY_BRANCH && \ +git pull upstream $__MISSKEY_BRANCH && \ git stash && \ -git rebase -f upstream/master && \ +git rebase -f upstream/$__MISSKEY_BRANCH && \ git branch patch-autogen && \ git checkout patch-autogen && \ git reset --hard HEAD || \ @@ -20,12 +21,12 @@ exit 1 touch patreon.md.cache && \ rm patreon.md.cache && \ echo '' > patreon.md.cache && \ -URL="https://www.patreon.com/api/oauth2/v2/campaigns/$CAMPAIGN_ID/members?include=currently_entitled_tiers,user&fields%5Btier%5D=title&fields%5Buser%5D=full_name,thumb_url,url,hide_pledges" +url="https://www.patreon.com/api/oauth2/v2/campaigns/$__MISSKEY_CAMPAIGN_ID/members?include=currently_entitled_tiers,user&fields%5Btier%5D=title&fields%5Buser%5D=full_name,thumb_url,url,hide_pledges" while : do touch patreon.raw.cache && \ rm patreon.raw.cache && \ - curl -LSs -w '\n' -H "Authorization: Bearer $BEARER_TOKEN" -- $URL > patreon.raw.cache && \ + curl -LSs -w '\n' -H "Authorization: Bearer $__MISSKEY_BEARER_TOKEN" -- $url > patreon.raw.cache && \ touch patreon.cache && \ rm patreon.cache && \ cat patreon.raw.cache | \ @@ -42,31 +43,31 @@ while : xargs -I% echo '