Git Product home page Git Product logo

nationalarchives.tna-child-domesday's Introduction

tna-base child theme template

This should be used when creating new child themes for tna-base

1.0 Clone Github repository 'tna-base-child-template' using SourceTree

Click 'Remote' in SourceTree and you will be shown a full list of repositories you have access to. Then:

  • Create a folder called 'tna-base-child-template' in the Themes directory of your WordPress installation where 'tna-base' parent theme sits
  • Select the 'tna-base-child-template' repository in SourceTree and clone it to your newly created 'tna-base-child-template' directory

1.1 Create your child theme from 'tna-base-child-template'

  • Create a folder in the Themes directory of your WordPress installation where 'tna-base' parent sits and give it a name
  • Use the naming convention, 'tna-child-...'
  • Copy the files inside 'tna-base-child-template' into your new child theme folder

1.2 Add existing local repository (your newly created child theme) to Github using SourceTree

  • Click on 'New repository' and select 'Add existing local repository'
  • Browse and select your newly created folder
  • Check 'Also create remote repository' and click 'Create'
  • Change owner to 'nationalarchives', uncheck 'This is a private repository' and click 'Create'
  • In SourceTree stage the files and make the first commit
  • Click on 'Git Flow' to create the desired branches to begin development
  • Push both branches 'master' and 'develop' to the remote repository

1.2.1 Adding new repository to Travis CI

Log into your Travis CI account and navigate to The National Archives organisation. Here you will be able to add the repository to Travis CI.

1.3 Create a new project for the WordPress installation in PhpStorm

  • Select 'Create New Project from Existing Files'
  • Select 'Web server is installed locally, source files are located under its document root'
  • Set /Applications/MAMP/htdocs/sites/tna-base-dev/wp-content/themes/tna-child-... and click 'Project Root'
  • Specify parameters for a new server as:

1.4 Installing dependencies

This repository is configured to allow for easy integration with Travis CI (Continuous Integration).

1.4.1 Obtaining dependencies via Composer

Having followed the steps above you will be able to install dependencies by typing composer install at the Terminal.

1.4.2 Obtaining dependencies via NPM

Type npm install to obtain Node dependencies

1.5 Running PHPUnit

Having followed the steps under 'Obtaining dependencies via Composer' type vendor/bin/phpunit -c phpunit.xml from within the tna-base directory to run Unit Tests for the project.

Note: PhpStorm allows for PHPUnit integration - allowing your tests to be run automatically. Search the JetBrains website to find out how to configure this.

1.6 Running Jasmine tests

Having obtained the dependencies you can type grunt jasmine to run JavaScript tests

nationalarchives.tna-child-domesday's People

Contributors

punalsc 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.