forked from zeekay/dot-files
-
Notifications
You must be signed in to change notification settings - Fork 0
/
ellipsis.sh
45 lines (39 loc) · 955 Bytes
/
ellipsis.sh
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
#!/usr/bin/env bash
#
# zeekay/files
#
# Dotfiles for various common bsd/unix utilities.
pkg.link() {
fs.link_files common
case $(os.platform) in
cygwin)
fs.link_files platform/cygwin
;;
osx)
fs.link_files platform/osx
;;
freebsd)
fs.link_files platform/freebsd
;;
linux)
fs.link_files platform/linux
;;
esac
}
git-configured() {
for key in user.name user.email github.user; do
if [ -z "$(git config --global $key | cat)" ]; then
return 1
fi
done
return 0
}
pkg.install() {
git.add_include '~/.gitinclude'
git.configured || cat <<\EOF
You should set your email, name and github user for git with `git config`:
git config --global user.name "Zach Kelling"
git config --global user.email "zk@monoid.io"
git config --global github.user "zeekay"
EOF
}