Repository for twolfson.com
MIT License
Repository for https://twolfson.com/
This server is written on top of express, for routing and views, and jojo, for blog entries.
We use inuit.css
as our CSS framework to provide OOCSS and BEM conventions.
The following steps will get a server running locally:
# Clone the repository
git clone https://github.com/twolfson/twolfson.com
cd twolfson.com
# Install our dependencies
npm install
# Run the server
npm start # should say 'Server running at http://localhost:8080/'
# For continuous development, use `nodemon`
# nodemon -x bin/twolfson.com
The server should be accessible via your browser at http://localhost:8080/
Our secrets are stored in environment variables. To update a secret, update it in:
.env.development
with a mock example.env.development.local
for actual usage/etc/supervisord.conf
Historically we used SOPS but it was overkill for a simple blog server, and setup across new computers was tedious with no extra value.
Additional documentation can be found in:
Our CSS is written in SASS.
CSS compilation is run by default as part of the main gulp build
task but can be run standalone:
gulp build-css
Images are compiled into spritesheets via gulp.spritesmith
. These are run via a standalone gulp
task:
gulp sprite
External JS libraries are managed via bin/bootstrap.sh
. To install the latest versions, please run:
bin/bootstrap.sh
As with CSS these are run by default as part of the main gulp build
task but can be run standalone:
gulp build-js
We leverage gulp
to automatically re-run JS and CSS tasks when their files change.
Additionally, they are integrated with LiveReload. When the complementary browser extension is installed, your browser will automatically reload CSS or refresh the page upon changes.
npm run develop
LiveReload extension: https://livereload.com/extensions/
articles/
- GitHub Flavored Markdown files for blog postsbin/twolfson.com
- Executable to start twolfson.com
locallyconfig/
- Static configuration files and resource initializationdist/
- Minified public filesserver/
- Container for majority of app
index.js
- Constructor for server that binds view and routing middlewarescontrollers/
- Business logic for server endpointsmodels/
- External data for the server to read inroutes.js
- Attachements for controllers/
to URLsviews/
- HTML templates written in Jade
public/
- CSS, images, and JavaScript for client side pagestest/
- Container for various test types
integrations-tests/
- BDD tests written in mocha that test server behaviorperceptual-tests/
- Perceptual diffs that detect visual changes across pagesproduction-tests/
- BDD tests written in Mocha for [twolfson.com][twolfson.com]utils/
- Common utilities used for starting up/tearing down servers and making HTTP requestsCHANGELOG.md
- Record of changes that have happened on the serverREADME.md
- Documentation for the projectgulpfile.js
- Configuration for various tasks via gulp
Support this project and others by twolfson via donations.
https://twolfson.com/support-me
Copyright (c) 2013-2014 Todd Wolfson
Licensed under the MIT license.