Skip to content

Commit

Permalink
Merge pull request #117 from primer/remove_font
Browse files Browse the repository at this point in the history
Removing the webfont and everything that builds the webfont
  • Loading branch information
jonrohan authored Sep 9, 2016
2 parents 62c6727 + 66f1a80 commit 78212f5
Show file tree
Hide file tree
Showing 18 changed files with 19 additions and 1,507 deletions.
8 changes: 8 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -1,5 +1,13 @@
### HEAD

### 5.0.0

Removes:

- Deprecating support for the webfont

### 4.4.0

Adds:

- svg.json file that is accessible from node require
Expand Down
45 changes: 2 additions & 43 deletions Gruntfile.js
Original file line number Diff line number Diff line change
Expand Up @@ -33,8 +33,7 @@ module.exports = function(grunt) {
},
dist: {
files: {
'build/octicons.min.css': 'build/octicons.css',
'build/font/octicons.min.css': 'build/font/octicons.css'
'build/octicons.min.css': 'build/octicons.css'
}
}
},
Expand Down Expand Up @@ -81,45 +80,7 @@ module.exports = function(grunt) {
}
},

webfont: {
options: {
font: "octicons",
fontFamilyName: "Octicons",
types: 'eot,woff,woff2,ttf,svg',
fontHeight: 96,
normalize: false,
ascent: 84,
descent: 12,
htmlDemo: false,
codepointsFile: 'lib/font/codepoints.json',
templateOptions: {
baseClass: 'octicon',
classPrefix: 'octicon-',
mixinPrefix: 'octicon-',
fontFamilyName: "Octicons"
}
},
octicons_css: {
src: 'lib/svg/*.svg',
dest: 'build/font',
options: {
template: 'lib/font/template.css'
}
},
octicons_scss: {
src: 'lib/svg/*.svg',
dest: 'build/font',
options: {
stylesheet: 'scss',
template: 'lib/font/template.scss'
}
}
},

clean: {
font: [
'build/font/*'
],
svg: [
'build/svg/*',
'build/sprite.octicons.svg',
Expand All @@ -131,18 +92,16 @@ module.exports = function(grunt) {
grunt.loadNpmTasks('grunt-contrib-clean');
grunt.loadNpmTasks('grunt-postcss');
grunt.loadNpmTasks('grunt-svg-sprite');
grunt.loadNpmTasks('grunt-webfont');
grunt.loadNpmTasks('grunt-svgmin');
grunt.loadNpmTasks('grunt-cssnano');
grunt.loadNpmTasks('grunt-sass');

// build tasks
grunt.registerTask('css', ['sass', 'postcss', 'cssnano']);
grunt.registerTask('font', ['clean:font', 'webfont']);
grunt.registerTask('svg', ['clean:svg', 'svgmin', 'svg_sprite']);

// default task, build /dist/
grunt.registerTask('default', [ 'svg', 'font', 'css', 'svg_json']);
grunt.registerTask('default', [ 'svg', 'css', 'svg_json']);

grunt.registerTask('svg_json', 'create a json object with all minimized svg', function() {
var result = {}
Expand Down
8 changes: 4 additions & 4 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -38,8 +38,8 @@ You’ll next need to build your Octicons.
All the files you need will be in the `/build/` directory already, but if you’ve made changes to the `/lib/` directory and need to regenerate, follow these steps:

1. Open the Octicons directory in Terminal
2. Run the command `script/bootstrap`. This will install any necessary dependencies for generating the Octicons font and SVGs.
3. Run the command `grunt`. Running the grunt task will generate the font and SVGs, placing them in the `/build/` directory.
2. `npm install` to install all dependencies for the project.
3. Run the command `npm run build`. This will run the grunt task to build the SVGs, placing them in the `/build/` directory.

## Publishing

Expand All @@ -56,8 +56,8 @@ If you have access to publish this repository, these are the steps to publishing

When using the GitHub logos, be sure to follow the [GitHub logo guidelines](https://github.com/logos).

_Font License:_ [SIL OFL 1.1](http://scripts.sil.org/OFL)
Applies to all font files and SVG files
_SVG License:_ [SIL OFL 1.1](http://scripts.sil.org/OFL)
Applies to all SVG files

_Code License:_ [MIT](./LICENSE)
Applies to all other files
Expand Down
Loading

0 comments on commit 78212f5

Please sign in to comment.