Skip to content

Commit

Permalink
Merge pull request #13 from intactile/master
Browse files Browse the repository at this point in the history
Release new version 1.007
  • Loading branch information
LaurentSpaggiari authored Mar 12, 2019
2 parents 4a1f3ff + 18c3c42 commit 8ca195f
Show file tree
Hide file tree
Showing 4,797 changed files with 385 additions and 368 deletions.
The diff you're trying to view is too large. We only load the first 3000 changed files.
300 changes: 300 additions & 0 deletions EPL-2.0.html

Large diffs are not rendered by default.

261 changes: 0 additions & 261 deletions epl-v10.html

This file was deleted.

Binary file modified fonts/ttf/B612-Bold.ttf
Binary file not shown.
Binary file modified fonts/ttf/B612-BoldItalic.ttf
Binary file not shown.
Binary file modified fonts/ttf/B612-Italic.ttf
Binary file not shown.
Binary file modified fonts/ttf/B612-Regular.ttf
Binary file not shown.
Binary file modified fonts/ttf/B612Mono-Bold.ttf
Binary file not shown.
Binary file modified fonts/ttf/B612Mono-BoldItalic.ttf
Binary file not shown.
Binary file modified fonts/ttf/B612Mono-Italic.ttf
Binary file not shown.
Binary file modified fonts/ttf/B612Mono-Regular.ttf
Binary file not shown.
102 changes: 35 additions & 67 deletions scripts/build.sh
Original file line number Diff line number Diff line change
@@ -1,101 +1,69 @@
#!/bin/sh
#!/bin/bash

# '-e' stop on the first failure
# '-u' prevent using an undefined variable
# '-o pipefail' force pipelines to fail on the first non-zero status code
# "-e" stop on the first failure
# "-u" prevent using an undefined variable
# "-o pipefail" force pipelines to fail on the first non-zero status code
set -euo pipefail

readonly ARGS=$*
readonly REGULAR='../fonts/ttf/B612-Regular.ttf'
readonly ITALIC='../fonts/ttf/B612-Italic.ttf'
readonly BOLD='../fonts/ttf/B612-Bold.ttf'
readonly BOLDITALIC='../fonts/ttf/B612-BoldItalic.ttf'
readonly MONO_REGULAR='../fonts/ttf/B612Mono-Regular.ttf'
readonly MONO_ITALIC='../fonts/ttf/B612Mono-Italic.ttf'
readonly MONO_BOLD='../fonts/ttf/B612Mono-Bold.ttf'
readonly MONO_BOLDITALIC='../fonts/ttf/B612Mono-BoldItalic.ttf'
FONT_TTFS=()
FONT_VFBS=()

readonly REGULAR_SOURCE='../sources/B612-Regular.vfb'
readonly ITALIC_SOURCE='../sources/B612-Italic.vfb'
readonly BOLD_SOURCE='../sources/B612-Bold.vfb'
readonly BOLDITALIC_SOURCE='../sources/B612-BoldItalic.vfb'
readonly MONO_REGULAR_SOURCE='../sources/B612Mono-Regular.vfb'
readonly MONO_ITALIC_SOURCE='../sources/B612Mono-Italic.vfb'
readonly MONO_BOLD_SOURCE='../sources/B612Mono-Bold.vfb'
readonly MONO_BOLDITALIC_SOURCE='../sources/B612Mono-BoldItalic.vfb'

readonly REGULAR_UFO='../fonts/ufo/B612-Regular.ufo'
readonly ITALIC_UFO='../fonts/ufo/B612-Italic.ufo'
readonly BOLD_UFO='../fonts/ufo/B612-Bold.ufo'
readonly BOLDITALIC_UFO='../fonts/ufo/B612-BoldItalic.ufo'
readonly MONO_REGULAR_UFO='../fonts/ufo/B612Mono-Regular.ufo'
readonly MONO_ITALIC_UFO='../fonts/ufo/B612Mono-Italic.ufo'
readonly MONO_BOLD_UFO='../fonts/ufo/B612Mono-Bold.ufo'
readonly MONO_BOLDITALIC_UFO='../fonts/ufo/B612Mono-BoldItalic.ufo'
for style in "Regular" "Italic" "Bold" "BoldItalic"
do
FONT_TTFS+=("../fonts/ttf/B612-$style.ttf")
FONT_TTFS+=("../fonts/ttf/B612Mono-$style.ttf")
FONT_VFBS+=("../sources/vfb/B612-$style.vfb")
FONT_VFBS+=("../sources/vfb/B612Mono-$style.vfb")
done

# -----------------------------------------------------------------------------
# ---- UTILS ------------------------------------------------------------------
# -----------------------------------------------------------------------------
log() {
message=$1; shift
color=$1; shift
nc='\033[0m\n'
nc="\033[0m\n"
printf "${color}[DEPLOY] $message$nc";
}

info() {
message=$1; shift
green='\033[0;32m'
green="\033[0;32m"
log "$message" "$green"
}

warn() {
message=$1; shift
red='\033[0;31m'
red="\033[0;31m"
log "$message" "$red"
}

# -----------------------------------------------------------------------------
# ---- STEPS ------------------------------------------------------------------
# ---- MAIN -------------------------------------------------------------------
# -----------------------------------------------------------------------------
fixDSIG() {
info "Fix font digital signature (DSIG)"
gftools fix-dsig --autofix $REGULAR $ITALIC $BOLD $BOLDITALIC $MONO_REGULAR $MONO_ITALIC $MONO_BOLD $MONO_BOLDITALIC
}

fixNonHinting() {
info "Fix font GASP and PREP table"
gftools fix-nonhinting $REGULAR $REGULAR
gftools fix-nonhinting $ITALIC $ITALIC
gftools fix-nonhinting $BOLD $BOLD
gftools fix-nonhinting $BOLDITALIC $BOLDITALIC
gftools fix-nonhinting $MONO_REGULAR $MONO_REGULAR
gftools fix-nonhinting $MONO_ITALIC $MONO_ITALIC
gftools fix-nonhinting $MONO_BOLD $MONO_BOLD
gftools fix-nonhinting $MONO_BOLDITALIC $MONO_BOLDITALIC
}
main() {
info "Fix font digital signature (DSIG) / Fix font GASP and PREP table"

for ttf in ${FONT_TTFS[*]}
do
echo $ttf
gftools fix-dsig --autofix $ttf
gftools fix-nonhinting $ttf $ttf
done

ufoExport() {
info "Export vfb as UFO"
vfb2ufo $REGULAR_SOURCE $REGULAR_UFO
vfb2ufo $ITALIC_SOURCE $ITALIC_UFO
vfb2ufo $BOLD_SOURCE $BOLD_UFO
vfb2ufo $BOLDITALIC_SOURCE $BOLDITALIC_UFO
vfb2ufo $MONO_REGULAR_SOURCE $MONO_REGULAR_UFO
vfb2ufo $MONO_ITALIC_SOURCE $MONO_ITALIC_UFO
vfb2ufo $MONO_BOLD_SOURCE $MONO_BOLD_UFO
vfb2ufo $MONO_BOLDITALIC_SOURCE $MONO_BOLDITALIC_UFO
}
info "Export vfb as UFO and normalize UFO"

# -----------------------------------------------------------------------------
# ---- MAIN -------------------------------------------------------------------
# -----------------------------------------------------------------------------
main() {
fixDSIG
# fixNonHinting
ufoExport
for vfb in ${FONT_VFBS[*]}
do
ufo=${vfb//vfb/ufo}
echo $ufo
vfb2ufo -fo $vfb $ufo
psfnormalize $ufo
done

info "FONT build"
info "Finished building B612 font"
exit 0;
}

Expand Down
Loading

0 comments on commit 8ca195f

Please sign in to comment.