README.adoc 1.9 KB

1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253545556575859
  1. = API Temps Réel
  2. :uri-bespoke: http://markdalgleish.com/projects/bespoke.js
  3. :uri-bundler: http://bundler.io
  4. :uri-generator-bespoke: https://github.com/bespokejs/generator-bespoke
  5. :uri-gulp: https://gulpjs.com
  6. :uri-node: https://nodejs.org
  7. :uri-nvm: https://github.com/creationix/nvm
  8. :uri-ruby: https://www.ruby-lang.org
  9. :uri-rvm: http://rvm.io
  10. [quote]
  11. A {uri-bespoke}[Bespoke.js] presentation generated by {uri-generator-bespoke}[generator-bespoke].
  12. == View slides locally
  13. First, ensure you have the following installed:
  14. . {uri-node}[Node.js] >= 4.2 footnote:[We strongly recommend using {uri-nvm}[nvm] to manage Node.]
  15. . {uri-gulp}[Gulp] (command line interface only)
  16. $ npm install -g gulp-cli
  17. Next, install dependencies (if you ran the generator with the `--skip-install` switch):
  18. $ npm install
  19. Finally, build and serve the presentation!
  20. $ gulp serve
  21. You can view the presentation in your browser at the URL displayed in the console.
  22. By default, the preview server runs on port 8080.
  23. To change this default, you can assign a different number to the PORT environment variable:
  24. $ PORT=8888 gulp serve
  25. To build the presentation without starting the preview server, use:
  26. $ gulp
  27. In both cases, the files are built into the [.path]_dist_ directory.
  28. You can view the slides outside of the local preview server by navigating to [.path]_dist/index.html_ in your browser.
  29. == Publish to GitHub Pages
  30. The Gulp build includes a task to publish your presentation to GitHub Pages.
  31. First, make sure you have initialized the project as a git repository and linked it to a GitHub project.
  32. The task assumes that the git remote named `origin` points to the repository on GitHub.
  33. Now you can build the presentation and publish it to GitHub Pages using:
  34. $ gulp publish
  35. The files in the [.path]_dist_ directory end up in the `gh-pages` branch in the repository on GitHub.
  36. From there, they can be viewed in a browser from anywhere on the web.