Git Product home page Git Product logo

instantclick-website's Introduction

This is the code that generates http://instantclick.io/, which is made of static files.

It has two parts:

  1. A regular PHP app (index.php, pages/, includes/, files/), used to preview what’s happening while developing/writing.

  2. A static file generator, generate_static_files.php, which runs the preview on each page and save it as an HTML file in output/.

To generate static files, type make into a terminal.

You’ll need PHP 5.4 and nginx to run the preview app, you’ll need PHP 5.4 to generate the static files.

The content (HTML) is in pages/. It’s organized by folders on disk but those folders’ names aren’t visible in the URL when visiting the site.

Deploying with Git

On your server:

cd /wherever
mkdir instantclick.git
cd instantclick.git
git init --bare
nano hooks/post-receive
  git --work-tree=/home/alex/instantclick.site --git-dir=/home/alex/instantclick.git checkout -f
  make -C /home/alex/instantclick.site
chmod +x hooks/post-receive
mkdir ../instantclick.site

Locally:

git remote add production ssh://server/wherever/instantclick.git
git push production master

Contributing

To keep a consistent tone I’ll end up editing most contributions. This means that for anything related to the copy (except for minor things, such as typos) you should open an issue first instead of a pull request. You’ll then be credited in the commit message.

I’m not a native English speaker, so if anything sounds weird, please tell me!

I’m also not a crackerjack back-end developer either, so if you spot anything that would make the code simpler to use/maintain, advice or pull requests are appreciated.

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.