From 3a38b2dba78ae59ff6965231b72014fcb60c9356 Mon Sep 17 00:00:00 2001 From: Levi Neely Date: Thu, 9 Apr 2026 15:53:31 +0200 Subject: [PATCH] add Gdifs, update Gdif to scope to $samfile --- git/Gdif | 5 ++++- git/Gdifs | 5 +++++ mkfile | 4 +++- php/Phpl | 6 ++++++ 4 files changed, 18 insertions(+), 2 deletions(-) create mode 100755 git/Gdifs create mode 100755 php/Phpl diff --git a/git/Gdif b/git/Gdif index 46cfe97..e196cec 100755 --- a/git/Gdif +++ b/git/Gdif @@ -1,2 +1,5 @@ #!/usr/bin/env rc -git diff +if(~ $#samfile 0) + git diff +if not + git diff $samfile diff --git a/git/Gdifs b/git/Gdifs new file mode 100755 index 0000000..972bbb0 --- /dev/null +++ b/git/Gdifs @@ -0,0 +1,5 @@ +#!/usr/bin/env rc +if(~ $#samfile 0) + git diff --staged +if not + git diff --staged $samfile diff --git a/mkfile b/mkfile index 4e8d634..ea4ca3e 100644 --- a/mkfile +++ b/mkfile @@ -5,12 +5,14 @@ install:V: cp git/G-- $HOME/bin/G-- cp git/Gc $HOME/bin/Gc cp git/Gdif $HOME/bin/Gdif + cp git/Gdifs $HOME/bin/Gdifs cp git/Gdn $HOME/bin/Gdn cp git/Gds $HOME/bin/Gds cp git/Gf $HOME/bin/Gf cp git/Gpat $HOME/bin/Gpat cp git/Gst $HOME/bin/Gst cp git/Gup $HOME/bin/Gup + cp php/Phpl $HOME/bin/Phpl clean:V: - rm -f $HOME/bin/G+ $HOME/bin/G++ $HOME/bin/G- $HOME/bin/G-- $HOME/bin/Gc $HOME/bin/Gdif $HOME/bin/Gdn $HOME/bin/Gds $HOME/bin/Gf $HOME/bin/Gpat $HOME/bin/Gst $HOME/bin/Gup + rm -f $HOME/bin/G+ $HOME/bin/G++ $HOME/bin/G- $HOME/bin/G-- $HOME/bin/Gc $HOME/bin/Gdif $HOME/bin/Gdifs $HOME/bin/Gdn $HOME/bin/Gds $HOME/bin/Gf $HOME/bin/Gpat $HOME/bin/Gst $HOME/bin/Gup $HOME/bin/Phpl diff --git a/php/Phpl b/php/Phpl new file mode 100755 index 0000000..3334902 --- /dev/null +++ b/php/Phpl @@ -0,0 +1,6 @@ +#!/usr/bin/env rc +if(~ $#samfile 0) { + echo 'Phpl must be run inside acme' >[2=1] + exit 'no samfile' +} +php -l $samfile