Skip to content

checkout to branch before modify commit date #4

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 3 additions & 1 deletion .github/workflows/gccefi2linux.yml
Original file line number Diff line number Diff line change
Expand Up @@ -26,6 +26,7 @@ jobs:
env:
UPDATE_TOKEN: ${{ secrets.SYNC_COMMIT_DATE_NSTESTER_TOKEN }}
USER_NAME: 'nstester'
BRANCH: 'master'
run: |
builds_ws=$GITHUB_WORKSPACE
check_rc () {
Expand All @@ -36,9 +37,10 @@ jobs:
cd $builds_ws
git config --global user.name $USER_NAME
git config --global user.email $USER_NAME'@users.noreply.github.com'
git checkout $BRANCH
today=$(date -u +%Y-%m-%d);
GIT_COMMITTER_DATE=$(date -u -R -d "$today 00:00:00") git commit --amend --no-edit
git push -f https://$USER_NAME:[email protected]/${{ github.repository }} HEAD:master
git push -f https://$USER_NAME:[email protected]/${{ github.repository }} HEAD:$BRANCH
DEPLOY_WS=${builds_ws}/deploy/linux_prod
rm -rf objdir ${DEPLOY_WS}
mkdir -p objdir ${DEPLOY_WS}/linux
Expand Down