Skip to content
Snippets Groups Projects
Commit c15cd193 authored by Peter Nerlich's avatar Peter Nerlich
Browse files

update.sh: allow target to be specified

parent 47e9036b
No related branches found
No related tags found
No related merge requests found
Pipeline #22127 passed
#!/bin/sh #!/bin/sh
target="${1:-master}"
echo "reset target is $target"
# update meta repo # update meta repo
git fetch origin master git fetch origin "$target"
# use the latest commit on master, discard any local changes # use the latest commit on master, discard any local changes
git reset --hard origin/master git reset --hard "$target"
# sync repo urls # sync repo urls
git submodule sync --recursive git submodule sync --recursive
# update commits, discard any local changes # update commits, discard any local changes
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment