summary refs log tree commit diff
diff options
context:
space:
mode:
authorJune McEnroe <june@causal.agency>2020-09-11 20:49:19 -0400
committerJune McEnroe <june@causal.agency>2020-09-11 20:49:19 -0400
commit07fc93ec497ed8308dc8a151798110d9bef68731 (patch)
tree1eaea4405450d8686152ab0efc09a158a41afb92
parentAdd debian VM name to ssh (diff)
downloadsrc-07fc93ec497ed8308dc8a151798110d9bef68731.tar.gz
src-07fc93ec497ed8308dc8a151798110d9bef68731.zip
Use MacPorts rather than pkgsrc
My system is probably such a mess now...
-rw-r--r--home/.profile2
-rw-r--r--install.sh33
2 files changed, 13 insertions, 22 deletions
diff --git a/home/.profile b/home/.profile
index 796e975f..53942ba3 100644
--- a/home/.profile
+++ b/home/.profile
@@ -1,6 +1,6 @@
 _PATH=$PATH PATH=
 path() { [ -d "$1" ] && PATH="${PATH}${PATH:+:}${1}"; }
-for prefix in '' /usr/local /usr/pkg /usr /opt/pkg ~/.local; do
+for prefix in '' /usr/local /opt/local /usr/pkg /usr ~/.local; do
 	path "${prefix}/sbin"
 	path "${prefix}/bin"
 done
diff --git a/install.sh b/install.sh
index 55e071fa..46ebd926 100644
--- a/install.sh
+++ b/install.sh
@@ -2,34 +2,25 @@
 set -eu
 
 pkgAny='curl htop sl the_silver_searcher tree'
-pkgDarwin="${pkgAny}"
+pkgDarwin="${pkgAny} git neovim pkg-config"
 pkgFreeBSD="${pkgAny} ddate neovim"
 pkgLinux="${pkgAny} bc ctags gdb neovim openssh"
 pkgNetBSD="${pkgAny} vim"
 pkgOpenBSD="${pkgAny} neovim"
 
-pkgsrcTag='20171103'
-neovimTag='v0.4.3'
 Darwin() {
-	xcode-select --install || true
-	if [ ! -d /opt/pkg ]; then
-		tar="bootstrap-trunk-x86_64-${pkgsrcTag}.tar.gz"
-		url="https://pkgsrc.joyent.com/packages/Darwin/bootstrap/${tar}"
-		curl -O "$url"
-		sudo tar -pxz -f "$tar" -C /
-		rm "$tar"
-	fi
-	sudo pkgin update
-	sudo pkgin install $pkgDarwin
-	sudo ln -fs /opt/pkg/bin/gpg2 /usr/local/bin/gpg
-	if [ ! -f /usr/local/bin/nvim ]; then
-		tar='nvim-macos.tar.gz'
-		base='https://github.com/neovim/neovim/releases/download'
-		url="${base}/${neovimTag}/${tar}"
-		curl -L -O "$url"
-		sudo tar -x -f "$tar" -C /usr/local --strip-components 1
-		rm "$tar"
+	if [ ! -d /opt/local ]; then
+		dir=MacPorts-2.6.3
+		tar=${dir}.tar.bz2
+		curl -O "https://distfiles.macports.org/MacPorts/${tar}"
+		tar -x -f $tar
+		(cd $dir && ./configure)
+		make -C $dir
+		sudo make -C $dir install
+		rm -fr $tar $dir
 	fi
+	sudo /opt/local/bin/port selfupdate
+	sudo /opt/local/bin/port -N install $pkgDarwin
 }
 
 FreeBSD() {
r> 2022-02-20Remove unused mbs.len field from struct EditJune McEnroe 2022-02-19Remove unneeded includes in ui.cJune McEnroe 2022-02-19Reimplement tab completeJune McEnroe 2022-02-19Handle errors from editFn, etc.June McEnroe 2022-02-19Reimplement text macrosJune McEnroe 2022-02-19Factor out input handling to input.cJune McEnroe 2022-02-19Factor out window management to window.cJune McEnroe 2022-02-19Enable -Wmissing-prototypesJune McEnroe In other words, warn when a function is missing static. I don't see why this isn't in -Wextra. 2022-02-19Fix edit.[ch] license notice additional permissionsJune McEnroe 2022-02-19Run line editing testsJune McEnroe I know, it feels wrong. 2022-02-18Implement new line editing "library"June McEnroe Losing tab complete and text macros, for now. This new implementation works on an instance of a struct and does not interact with the rest of catgirl, making it possible to copy into another project. Unlike existing line editing libraries, this one is entirely abstract and can be rendered externally. My goal with this library is to be able to implement vi mode. Since it operates on struct instances rather than globals, it might also be possible to give catgirl separate line editing buffers for each window, which would be a nice UX improvement. 2022-02-18Simplify cursor positioning in inputJune McEnroe Do some extra work by adding the portion before the cursor to the input window twice, but simplify the interaction with the split point. This fixes the awkward behaviour when moving the cursor across colour codes where the code would be partially interpreted up to the cursor. 2022-02-18Fix M-f orderingJune McEnroe 2022-02-12Move sandman build to scripts/MakefileJune McEnroe 2022-02-12Use compat_readpassphrase.c on LinuxJune McEnroe 2022-02-12Copy RPP defines from oconfigureJune McEnroe