Skip to content

Commit e138d6f

Browse files
committed
Update readme
1 parent 252aeb6 commit e138d6f

File tree

1 file changed

+1
-13
lines changed

1 file changed

+1
-13
lines changed

readme.md

Lines changed: 1 addition & 13 deletions
Original file line numberDiff line numberDiff line change
@@ -11,19 +11,7 @@ Download the script (`wget https://github.com/X1011/git-directory-deploy/raw/mas
1111
- **repo**: repository to deploy to. Must be readable and writable. The default of "origin" will not work on Travis CI, since it uses the read-only git protocol. In that case, it is recommended to store a [GitHub token](https://help.github.com/articles/creating-an-access-token-for-command-line-use) in a [secure environment variable](http://about.travis-ci.org/docs/user/build-configuration/#Secure-environment-variables) and use it in an HTTPS URL like this: <code>repo=https://$GITHUB_TOKEN@github.com/<i>user</i>/<i>repo</i>.git</code>
1212

1313
## setup
14-
Do this once to set up a deploy branch if you don't already have one. This could be implemented in the script, but I don’t feel like doing it. Replace "dist" with your deploy_directory and "gh-pages" with your deploy_branch.
15-
16-
1. `git --work-tree dist checkout --orphan gh-pages`
17-
- this will disconnect the gh-pages branch’s history from the current commit
18-
- in my app, the project root and dist had no files in common. If yours do, be careful if you don’t want to overwrite any existing files in dist
19-
2. `git --work-tree dist rm -r "*"`
20-
- remove the source files we just checked out; these aren’t the files we’re looking for
21-
- the quotes are required to prevent the shell from globbing in the current directory; we want git to glob in dist
22-
3. `git --work-tree dist add --all`
23-
4. `git --work-tree dist commit -m "initial publish"`
24-
5. `git push origin gh-pages`
25-
6. `git symbolic-ref HEAD refs/heads/master && git reset --mixed`
26-
- switch back to master branch
14+
Ensure configuration variables are correct in `deploy.sh` and run `./deploy.sh -s`
2715

2816
## run
2917
Do this every time you want to deploy, or have your CI server do it.

0 commit comments

Comments
 (0)