Coder Social home page Coder Social logo

dskvr / bpkg.github.io Goto Github PK

View Code? Open in Web Editor NEW

This project forked from bpkg/bpkg.github.io

0.0 1.0 0.0 450 KB

Homepage for the bpkg project http://bpkg.sh

JavaScript 11.72% Ruby 11.18% CSS 30.86% HTML 16.07% Liquid 0.55% Dockerfile 0.15% Less 29.47%

bpkg.github.io's Introduction

bpkg.github.io (bpkg.sh)

bpkg is a lightweight bash package manager. This repository contains the source code of it's homepage.

Links

bpkg Commands

To assist in working with this project, A bpkg.json file has been included with commonly used project commands. The provided commands can be executed using the following format:

$ bpkg run [COMMAND]

In the remainder of this document, if there is a accompanying bpkg command it will be listed as follows:

BPKG: [COMMAND]

Docker Environment

This environment is not necessary to use if you'd rather run everything directly on your host system. This environment is provided however, to facilitate all the required components for building and development of bpkg site.

A docker-composer.yml file exists in the root directory of the project to specify the Docker services

  • jekyll – Perform Jekyll and Rake processes

    NOTE: A custom Dockerfile exists to generate the image for this service, in the dev/jekyll directory

  • lessc – Implements LESS preprocessing
  • sitediff – Host SiteDiff for performing site comparison

There are associated bpkg commands to interact with the Docker environments, accompanying Docker commands will be listed like the other bpkg commands.

Dependencies

This website was made with the Jekyll engine, so it depends on a few Ruby Gems. To install them, run the following command:

$ gem install jekyll

It might take a while to finish, but once it does you're ready to go.

Edit Site Pages

To make changes to the page or run it locally, clone this GitHub repository and make sure you have installed the dependencies above.

Then, it's a matter of editing pages and running rake tasks. Here's a rundown of possible commands (thanks to this great quickstart on Jekyll).

Preview Site

$ rake preview

BPKG: preview
BPKG: docker-preview

Builds the entire site to a local folder _site and launches a webserver to preview it.

To see the full site, point your browser to localhost:4000.

If you make any changes on any files, it will regenerate the website automatically.

Create Post

$ rake post title="Hello, World!"

BPKG: post title="Hello, World!"
BPKG: docker-post title="Hello, World!"

Creates a new post. It will create a file _posts/YYYY-MM-DD-title.md, where the date is the current, by default.

No further changes are required, the post will get automatically inserted on the site.

Create Page

$ rake page name="about"

BPKG: page name="about"
BPKG: docker-page name="about"

Creates a new page. It will create the file ./about/index.html.

$ rake page name="about.html"

BPKG: page name="about.html"
BPKG: docker-page name="about.html"

Alternative way to create a new page, on this case it will be ./about.html.

Update Style Sheets

This project uses LESS (Leaner Style Sheets) files to generate the CSS for this site. When modifying the site style sheets under the /assets directory, update the LESS files (ie: *.less). To update the CSS file after making changes to any of the LESS files, run the following command (from the root of the project):

$ lessc ./assets/themes/the-program/css/style.less ./assets/themes/the-program/css/style.css

BPKG: lessc
BPKG: docker-lessc

View Site Changes

When working on the site, sometimes it's helpful to see changes between the production copy and the output of local changes. A report of changes can be generated with the SiteDiff tool, to simplify this process a Docker service has been included with a few bpkg commands. This is a multi-step process (each step has an associated 'bpkg' command), but a single command can be used to run all the steps. Before performing these steps the local version needs to be in preview mode.

SiteDiff - Crawl Sites

The SiteDiff utility will crawl the production and the preview versions of the site prior to performing the comparison:

BPKG: site-crawl

SiteDiff - Diff Crawled Sites

After crawling the versions of the sites, SiteDiff will compare the preview against the production version and generate a change report:

BPKG: site-diff

SiteDiff - Serve Report

The generated report can be served for viewing by SiteDiff:

BPKG: site-serve

To see the report, point your browser to localhost:13080.

SiteDiff

The preceding command performs the following steps (which can be run individually):

BPKG: sitediff

Notes

  • When producing content (writing pages/posts) keep in mind this useful guide. It tells how to include images, display post excerpts and highlight code snippets.
  • If you plan on further customizing the blog, it's highly recommended to read this 10-minute introduction to Jekyll.
  • If you change settings on the file _config.yml, automatic regeneration won't work - you'll have to run the command rake preview again.

Credits

This site uses Jekyll Bootstrap with a heavily customized version of the_program theme, originally made by Yuya Saito.

bpkg.github.io's People

Contributors

alexdantas avatar jwerle avatar samlikins avatar potherca avatar brock avatar yorkie avatar pepa65 avatar kirtfitzpatrick avatar moraxy avatar bntzio avatar jwithington avatar krasjet avatar rylnd avatar lordvlad avatar yubele avatar qzb avatar kdwarn avatar lafkpages avatar martin-schulze-vireso avatar nathanabercrombie avatar sugarshin avatar particleflux avatar kj4ezj avatar xdb64 avatar sinkcup avatar brlin-tw avatar chemaclass avatar aurora avatar lurst avatar francescobianco avatar

Watchers

 avatar

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.