sway/scripts/prism/build.sh
Elvis 919c18c98f
added sway highlight.js (#129)
* added sway highlight.js

* added higlightjs/sway and its build script

* added initial prism for sway

* added script for prism

* added prism-sway and instructions

* rename to all caps

* update build scripts

* added missing dots
2021-08-02 19:09:28 +02:00

22 lines
427 B
Bash

#!/bin/bash
project="prism"
components="components.json"
sway="prism-sway.js"
if ! test -d ./${project}; then
git clone git@github.com:PrismJS/prism.git
fi
cp ${sway} ${project}/components
cp ${components} ${project}
cd ${project}
npm ci
npm run build
cp components/prism-sway.min.js ../prism-sway.min.js
# add "keep" in order to keep highlight.js repo
if [[ ${1} != "keep" ]]; then
cd ../
rm -rf ${project}
fi