Coder Social home page Coder Social logo

webdev's Introduction

Mozilla Webdev Tools and Pages

This repo serves several purposes:

  1. Contains code for building and deploying the gh-pages branch behind http://mozilla.github.io/webdev/.
  2. Contains small tools that are useful for the Mozilla Webdev group.

Developer Setup

These steps assume you have Node.js installed.

  1. Clone this repo:

    $ git clone https://github.com/mozilla/webdev.git
  2. Install dependencies:

    $ npm install -g gulp
    $ npm install
  3. (Optional) Add your Github credentials to a .env file in the repo's root. These are used by the build command when downloading metadata from Github. For security, you should probably use a Personal Access Token for the password and limit it to public_repo permissions only. For example:

    GITHUB_USERNAME=Osmose
    GITHUB_PASSWORD=some_personal_access_token
    

projects.json

projects.json contains a categorized list of projects the Webdev group is responsible for. It's intended to be manually kept up-to-date and is useful for running scripts across all Webdev projects.

Available Gulp Commands

gulp serve

Run a development server for the Github pages site on port 8000. Auto-builds the site when anything is changed in the src directory.

gulp build

Builds the site in the build directory. Runs all the HTML files through Nunjucks with the following context:

  • projects: Object containing the parsed contents of build/projects.json.

The metadata added to the projects list is downloaded from the Github API and is cached for 24 hours. The --force flag will force a re-download of this data.

Note that it's very easy to hit API limits if you haven't added your credentials to a .env file.

gulp deploy

Build the site and commit the changes to the gh-pages branch, pushing them to origin.

gulp validate_contribute_json

Fetch contribute.json files for all of the projects in projects.json and validate them. Currently only supports repos hosted on Github.

License

Licensed under the Apache 2.0 License. For details, see the LICENSE file.

webdev's People

Contributors

almet avatar ashwani99 avatar djmitche avatar erikrose avatar koddsson avatar mathjazz avatar mythmon avatar openjck avatar osmose avatar peterbe avatar pmac avatar pomax avatar suriyaakudoisc avatar sylvestre avatar thgreasi avatar tofumatt avatar willkg 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.