File: pre-commit

package info (click to toggle)
libcbor 0.5.0%2Bdfsg-2
  • links: PTS, VCS
  • area: main
  • in suites: bullseye, buster
  • size: 1,176 kB
  • sloc: ansic: 7,131; makefile: 154; sh: 71; python: 54; ruby: 17; cpp: 6
file content (14 lines) | stat: -rwxr-xr-x 294 bytes parent folder | download
1
2
3
4
5
6
7
8
9
10
11
12
13
14
#!/bin/sh

set -e

# Refresh libcbor.org ...
cd docs 

if [[ $(git -C .. diff --cached --name-only) == *"index.html.erb"* ]]; then
	echo "The homepage template has been updated, regenerating and checking in the HTML."
	erb index.html.erb > index.html
	git -C .. add $(pwd)/index.html
fi

cd ..