Skip to content

Create a second git repo? #29

@jantimon

Description

@jantimon

I have an idea how you could improve the speed and commit only the files you need to gh-pages without having to push changes to master and without switching branches:

# prep steps
npm run build

# Use a sub folder called gh-pages
# We need a solution how we can pass the origin-url here:
git clone <origin-url> --depth 1 --single-branch -b gh-pages gh-pages

# Copy files e.g. static folder
cp -r dist/* gh-pages/
cd gh-pages

git add -A .
git commit -a -m 'A custom commit message'
git push origin gh-pages --force

cd ..
rm -rf gh-pages

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions