Setting up a Nanoc site on GitHub Pages

21 views
Skip to first unread message

Pito Salas

unread,
Apr 9, 2021, 4:01:05 PM4/9/21
to na...@googlegroups.com
I know you have detailed instructions but there are various things I don't understand. And, it's not working for me.

To start what does `git clone . output` do?

Also from what directory do I do the `git remote add origin repo-url` command?

And what is the repo-url, is it my ssh command?

Also from what directory do I do the `nanoc deploy` command?

And do I ever do a git commit + push again?

Thanks!


Pito Salas
Faculty, Computer Science
Brandeis University

Denis Defreyne

unread,
Apr 12, 2021, 3:19:51 PM4/12/21
to noreply-spamdigest via nanoc
Hey Pito,

I’ll answer inline:

To start what does `git clone . output` do? 
It creates `output` as a repository, cloned from the current working directory. (The way I think of it is `git clone` being analogous to `cp` in terms of the arguments it takes: “from” and “to”.). You could also clone it with something like `git clone g...@github.com:mygithubusername/myrepo.git output`, but the former is more convenient.

Also from what directory do I do the `git  remote add origin repo-url` command? 
This is from within the output directory (which was created by the `git clone . output` command earlier). The code snippets (on https://nanoc.ws/doc/deploying/#with-git) have a prompt that shows both the current directory (before the @) as well as the git branch (after the @, before the %).

I agree that this isn’t obvious, and I’m also not formatting the prompts quite consistently I admit, so I’ll see about improving that.

And what is the repo-url, is it my ssh command?
This is e.g. `g...@github.com:mygithubusername/myrepo.git`.

(This is not technically a URL, but Git calls it a URL.)

Also from what directory do I do the `nanoc deploy` command? 
You’d run this from your site’s directory, not from the output/ directory.

And do I ever do a git commit + push again?
No need — `nanoc deploy` will take care of that!

Hope this helps,

Denis Defreyne
[dəˈni] • pronouns: he/him

-- 
You received this message because you are subscribed to the Google Groups "nanoc" group.
To unsubscribe from this group and stop receiving emails from it, send an email to nanoc+un...@googlegroups.com.


Pito Salas

unread,
Apr 12, 2021, 6:37:10 PM4/12/21
to na...@googlegroups.com
Hi Denis

Yes, it did, Thanks! Some new git and gh magic I didn't know :)

I assume I treat the main (Nanoc-created) directory in the normal way and version control it with git add/git commit/git push etc.

Pito Salas
Faculty, Computer Science
Brandeis University

> To view this discussion on the web visit https://groups.google.com/d/msgid/nanoc/8ae087f5-bc92-45bd-a57e-44b4b04c3da5%40www.fastmail.com.

Reply all
Reply to author
Forward
0 new messages