From 42fa454df9cf79cf9cde7fc025b1504c53e3373a Mon Sep 17 00:00:00 2001 From: Anirudh Oppiliappan Date: Fri, 21 Feb 2025 10:21:56 +0200 Subject: [PATCH] more misc commit view improvements --- appview/pages/templates/repo/commit.html | 22 +++++++------------- scripts/appview.sh | 26 ++++++++++++++++++++++++ 2 files changed, 33 insertions(+), 15 deletions(-) create mode 100755 scripts/appview.sh diff --git a/appview/pages/templates/repo/commit.html b/appview/pages/templates/repo/commit.html index b361cef9..6d4679a2 100644 --- a/appview/pages/templates/repo/commit.html +++ b/appview/pages/templates/repo/commit.html @@ -65,24 +65,16 @@
{{ if .IsNew }} - A + A {{ end }} {{ if .IsDelete }} - D + D {{ end }} {{ if not (or .IsNew .IsDelete) }} - M + M {{ end }} - {{ if .Name.Old }} - {{ .Name.Old }} - {{ if .Name.New }} - → - {{ .Name.New }} - {{ end }} - {{ else }} - {{ .Name.New }} - {{- end -}} + {{ .Name.New }}
{{ $iconstyle := "p-1 mx-1 hover:bg-gray-100 rounded" }} @@ -110,15 +102,15 @@
{{ .Header }}
{{- range .Lines -}} {{- if eq .Op.String "+" -}} -
{{ .Op.String }}{{ .Line }}
+
{{ .Op.String }}{{ .Line }}
{{- end -}} {{- if eq .Op.String "-" -}} -
{{ .Op.String }}{{ .Line }}
+
{{ .Op.String }}{{ .Line }}
{{- end -}} {{- if eq .Op.String " " -}} -
{{ .Op.String }}{{ .Line }}
+
{{ .Op.String }}{{ .Line }}
{{- end -}} {{- end -}} diff --git a/scripts/appview.sh b/scripts/appview.sh new file mode 100755 index 00000000..045fc26e --- /dev/null +++ b/scripts/appview.sh @@ -0,0 +1,26 @@ +#!/bin/bash + +# Variables +BINARY_NAME="appview" +BINARY_PATH=".bin/app" +SERVER="95.111.206.63" +USER="appview" + +# SCP the binary to root's home directory +scp "$BINARY_PATH" root@$SERVER:/root/"$BINARY_NAME" + +# SSH into the server and perform the necessary operations +ssh root@$SERVER <