no-stack-dub-sack / cs-playground-react

In-Browser Algorithm and Data Structures Practice
http://cs-playground-react.surge.sh/
MIT License
520 stars 91 forks source link

GitHub pages deployment #11

Closed ishanjain28 closed 6 years ago

ishanjain28 commented 6 years ago

This PR is to have cs-playground-react deployed on Github Pages. I tried a few times and surge.sh link isn't working for me. It would be awesome if you can deploy it on github pages too.

I built it from the latest commit so merging this PR with a new gh-pages branch would get it online. Don't merge this PR without changing base branch.

ishanjain28 commented 6 years ago

In future, All you'll have to do is,

  1. Running yarn build.
  2. Switching to gh-pages branch.
  3. Removing all files except the new build folder.
  4. Move content in build/ to project root directory.
  5. Commit changes.
  6. Push.
no-stack-dub-sack commented 6 years ago

@ishanjain28 thanks for the PR, however, I'm only allowed one gh-pages deployment with my free account, and I already have one.

I'm a bit confused though, what do you mean you can't access the surge.sh link?

ishanjain28 commented 6 years ago

@no-stack-dub-sack When I was opening https://cs-playground-react.surge.sh/ yesterday it was not showing anything at all. It's working fine today.

What do you mean by "'m only allowed one gh-pages deployment with my free account, and I already have one."? Github pages are free.

I use Firefox 57 on Arch Linux. I guess it's working fine today, So Github pages deployment isn't necessary.

no-stack-dub-sack commented 6 years ago

@ishanjain28 glad it's working now, strange it wasn't yesterday. Could have been Surge's servers, I've heard they've been experiencing intermittent difficulties.

I haven't tried to deploy a second, but my understanding is that you only get one fully customizable deployment per free GH account, the others that you get are "project pages":

image

If you click on the button on the right there, you'll see that the "project pages" are not quite the same. I'm not positive, but based on this, I'm guessing GH might try to block me if I try to deploy another fully custom site to GH pages.

All that aside, if surge is working well (which it seems to be, I've logged 20,447 hits since the article was published with no notable crashes!), I'm thinking I'll just keep it simple and stick with the current setup, though I do appreciate your willingness to contribute!

no-stack-dub-sack commented 6 years ago

@ishanjain28 looks like I missed you last line before:

So Github pages deployment isn't necessary.

Thanks again for the suggestion though!