Mercurial > hg > cc > cirrus_home
changeset 185:acae526510e2
too many overdue updates to break down
author | Henry S. Thompson <ht@inf.ed.ac.uk> |
---|---|
date | Wed, 06 Dec 2023 13:38:58 +0000 |
parents | 53a8ffe06460 |
children | fc1b16130961 |
files | .bash_extras .hgrc .tmux.conf .xemacs/init.el bin/c2t.sh bin/runme_c.sh bin/s2t.sh lib/emacs/common-init.el lib/emacs/pers-init.el |
diffstat | 9 files changed, 39 insertions(+), 126 deletions(-) [+] |
line wrap: on
line diff
--- a/.bash_extras Fri Sep 08 21:44:48 2023 +0100 +++ b/.bash_extras Wed Dec 06 13:38:58 2023 +0000 @@ -1,82 +1,1 @@ -# Sourced by .bashrc - -cu () -{ - cvs update "$@" | egrep -v '^\?' -} - -lss () -{ - /bin/ls -l "$@" | sort -nr -k 5 -} - -ff () -{ - pat=$1; - shift; - find . -iname "*$pat*" $@ -} - -typecat () -{ - tt=$(type $1); - case $tt in - *\ is\ hashed\ *) - cat $(echo $tt | cut -f 4 -d ' ' | tr -d '()') - ;; - *\ is\ /*) - cat $(echo $tt | cut -f 3 -d ' ' | tr -d '()') - ;; - *) - type $1 - ;; - esac -} - -sus () -{ - sort "$@" | uniq -c | sort -k1nr,1 -} - -uz () -{ - igzip -dc "$@" -} - - -function typecat () -{ - tt=$(type $1) - case $tt in - *\ is\ hashed\ *) cat $(echo $tt | cut -f 4 -d ' ' | tr -d '()') ;; - *\ is\ /*) cat $(echo $tt | cut -f 3 -d ' ' | tr -d '()') ;; - *) type $1 ;; - esac -} - -function tot () -{ - awk '{sum+=$1} END {printf "%u\n",sum}' -} - -btot () -{ - python3 -c 'import sys -commas = False -if len(sys.argv)>1: - if sys.argv[1]=="-c": - commas = True -n=0 -for l in sys.stdin: - try: - n+=int(l) - except ValueError as e: - print(e,file=sys.stderr) -if commas: - print(f"{n:,}") -else: - print(n) -' "$@" -} - -export -f cu lss ff typecat sus uz tot btot +/work/dc007/dc007/hst/../shared/.bash_extras \ No newline at end of file
--- a/.hgrc Fri Sep 08 21:44:48 2023 +0100 +++ b/.hgrc Wed Dec 06 13:38:58 2023 +0000 @@ -11,3 +11,4 @@ # pager = # color = strip = +rebase =
--- a/.tmux.conf Fri Sep 08 21:44:48 2023 +0100 +++ b/.tmux.conf Wed Dec 06 13:38:58 2023 +0000 @@ -9,7 +9,7 @@ setw -g mode-keys emacs # cut-paste outside tmux. see https://linuxhint.com/copy-paste-clipboard-tmux/ -bind C-c run "tmux save-buffer - | /usr/bin/xclip -i -sel clipboard || :" +bind C-c run "tmux save-buffer /tmp/hst/clipped ; csing /usr/bin/xsel -b -i < /tmp/hst/clipped" bind C-v run 'tmux set-buffer "$(/usr/bin/xclip -o -sel clipboard)"; tmux paste-buffer' # https://superuser.com/questions/1098077/how-to-keep-terminal-window-title-in-sync-with-tmux-window
--- a/.xemacs/init.el Fri Sep 08 21:44:48 2023 +0100 +++ b/.xemacs/init.el Wed Dec 06 13:38:58 2023 +0000 @@ -1,11 +1,11 @@ (message "init 0") (defvar site-name 'cirrus "for site-specific initialisation") +;;; for jde??? +(fset 'custom-autoload-orig (symbol-function 'custom-autoload)) +(defun custom-autoload (a b c) (custom-autoload-orig a b)) (message "init 1") -(nconc load-path '("/lustre/home/dc007/hst/gentoo/usr/lib/xemacs/xemacs-packages/lisp/prog-modes" "/lustre/home/dc007/hst/gentoo/usr/lib/xemacs/xemacs-packages/lisp/python-modes" "/lustre/home/dc007/hst/gentoo/usr/lib/xemacs/xemacs-packages/lisp/xemacs-base" "/lustre/home/dc007/hst/gentoo/usr/lib/xemacs/xemacs-packages/lisp/text-modes" "/lustre/home/dc007/hst/gentoo/usr/lib/xemacs/xemacs-packages/lisp/edit-utils" "/lustre/home/dc007/hst/gentoo/usr/lib/xemacs/xemacs-packages/lisp/fsf-compat" "/lustre/home/dc007/hst/gentoo/usr/lib/xemacs/xemacs-packages/lisp/sh-script" "/lustre/home/dc007/hst/gentoo/usr/lib/xemacs/xemacs-packages/lisp/c-support" "/lustre/home/dc007/hst/gentoo/usr/lib/xemacs/xemacs-packages/lisp/dired" "/lustre/home/dc007/hst/gentoo/usr/lib/xemacs/xemacs-packages/lisp/ediff" "/lustre/home/dc007/hst/gentoo/usr/lib/xemacs/xemacs-packages/lisp/mail-lib")) +(load "~/lib/emacs/common-init" nil t) (message "init 2") -(load "~/lib/emacs/common-init" nil t) +(load "~/lib/emacs/pers-init" nil t) (message "init 3") -(load "~/lib/emacs/pers-init" nil t) -(require 'hideshow) -(require 'sh-script) -(message "init 4, hideshow loaded, should not be necessary") +
--- a/bin/c2t.sh Fri Sep 08 21:44:48 2023 +0100 +++ b/bin/c2t.sh Wed Dec 06 13:38:58 2023 +0000 @@ -7,7 +7,7 @@ #SBATCH --time=01:00:00 #SBATCH --partition=standard #SBATCH --qos=standard -#SBATCH --account=ec184-guest +#SBATCH --account=ec184-hst #SBATCH --job-name c2t export W=/work/dc007/dc007
--- a/bin/runme_c.sh Fri Sep 08 21:44:48 2023 +0100 +++ b/bin/runme_c.sh Wed Dec 06 13:38:58 2023 +0000 @@ -1,7 +1,7 @@ #!/usr/bin/bash -# Invoke this as e.g. sbatch --ntasks=10 -c 20 runme.sh [-m first last] [args for work/bin/_runme.sh] +# Invoke this as e.g. sbatch --ntasks=10 -c 20 runme.sh [-m ( '{...}' | first last)] [args for work/bin/_runme.sh] # It will run on the login node -# -m i j will launch _runme.sh multiple times with a -a in {first..last} +# -m i j will launch _runme.sh multiple times with a -a in {...} or {first..last} #SBATCH --time=01:00:00 #SBATCH --partition=standard @@ -13,8 +13,15 @@ if [ "$1" = "-m" ] then - ss={$2..$3} - shift; shift; shift; + shift + if [[ "$1" == {*} ]] + then + ss="$1" + shift + else + ss={$1..$2} + shift; shift + fi echo $(date) Launching $SLURM_JOB_NUM_NODES nodes in $(pwd) for runme_c -a $ss "$@" from $(hostname) to do $SLURM_NTASKS tasks, $SLURM_CPUS_PER_TASK cpus each 1>&2 for i in $(eval echo $ss) do
--- a/bin/s2t.sh Fri Sep 08 21:44:48 2023 +0100 +++ b/bin/s2t.sh Wed Dec 06 13:38:58 2023 +0000 @@ -5,12 +5,13 @@ #SBATCH --time=01:00:00 #SBATCH --partition=standard #SBATCH --qos=standard -#SBATCH --account=ec184-guest +#SBATCH --account=ec184-hst #SBATCH --job-name s2t export W=/work/dc007/dc007 echo $(date) Launching $SLURM_JOB_NUM_NODES nodes for s2t "$@" from $(hostname) to do $SLURM_NTASKS tasks, $SLURM_CPUS_PER_TASK cpus each -srun -c $SLURM_CPUS_PER_TASK $W/shared/bin/sing $W/hst/bin/_s2t.sh "$@" +srun -c $SLURM_CPUS_PER_TASK $W/shared/bin/csing $W/hst/bin/_s2t.sh "$@" +
--- a/lib/emacs/pers-init.el Fri Sep 08 21:44:48 2023 +0100 +++ b/lib/emacs/pers-init.el Wed Dec 06 13:38:58 2023 +0000 @@ -7,11 +7,6 @@ ;;; split into common-init for all my incarnations and pers-init for private ;;; added lemacs compatibility -;;; Screen -(let ((f (selected-frame))) - (set-frame-width f 81) - (set-frame-height f 48)) - ;;; mail stuff (setq mail-archive-file-name "~/mail/cpy/general") (setq rmail-dont-reply-to-names "hthompso*\\|h\\.thompso*\\|ht@*" ) @@ -54,12 +49,12 @@ (switch-to-buffer (make-shell "kcl" "kcl")) (inferior-lisp-mode)) -;(require 'mdn-extras) +(require 'mdn-extras) (setq auto-mode-alist (append '(("/perl/" . perl-mode) ("\\.scm$" . scheme-mode)) auto-mode-alist)) -;(setq inferior-lisp-program "/c/Progra~1/ChezSc~1.4/bin/i3nt/petite") +(setq inferior-lisp-program "/c/Progra~1/ChezSc~1.4/bin/i3nt/petite") ;;; for scheme (put 'letrec 'lisp-indent-function 1) (put 'case 'lisp-indent-function 1) @@ -85,7 +80,7 @@ (parc "prolog")))) (inferior-prolog-mode)) -(site-caseq ((laptop maritain cirrus)) +(site-caseq ((laptop maritain)) (t(require 'hist) (rplacd (assoc "*shell*" hk-pat-table) "[a-z]+<[0-9]+>: "))) @@ -101,7 +96,7 @@ ;(require 'compress) (if (string-match "Lucid" emacs-version) - (site-caseq ((laptop maritain cirrus)) + (site-caseq ((laptop maritain)) (t(require 'lemacs-compat)))) (if (boundp 'epoch::version) @@ -168,10 +163,10 @@ (font-lock-mode 1))) (add-hook 'python-mode-hook '(lambda () (font-lock-mode 1))) - ;(setq py-python-command "//c/Program Files/Python22/python") + (setq py-python-command "//c/Program Files/Python22/python") (setq sgml-insert-missing-element-comment nil) - ;(load "psgml" nil t) - ;(load "psgml-edit" nil t) + (load "psgml" nil t) + (load "psgml-edit" nil t) ;; (load "xml-hack" nil t) ; (setq sgml-catalog-files '("CATALOG" "f:/lib/sgml/catalog")) (if (string-match "i386" (emacs-version)) @@ -186,18 +181,14 @@ ; (require 'gnus-min) )) - (site-caseq ((cirrus)) - (t (load "gnus-init" nil t))) + (load "gnus-init" nil t) ;; (require 'idle) ;; (idle-save 15) (if (string-match "Lucid" emacs-version) ;; lemacs only goes here - (site-caseq ((cirrus) - ;(load "perl-mode" nil t) - ) - (t(progn + (progn (setq bbdb-north-american-phone-numbers-p nil) (setq bbdb-use-pop-up nil) (require 'bbdb) @@ -261,7 +252,7 @@ (unwind-protect (make-screen-for-room "mail" "-75" "+113")) (sit-for 1) (delete-screen scr)) - (setq ht-default-config (current-window-configuration))))))) + (setq ht-default-config (current-window-configuration))))) ;; vanilla v19 goes here (if window-system (progn @@ -271,7 +262,6 @@ (cursor-type . bar))) (nconc (site-caseq ((laptop maritain) (list '(height . 35))) - ((cirrus)) (t (list '(font . @@ -422,12 +412,7 @@ ((= pw 1920) ;; we're on a 27" curved external monitor (set-frame-pixel-size (selected-frame) 720 980) - (site-caseq (cirrus - (set-frame-position - (selected-frame) 0 0)) - (t - (set-frame-position - (selected-frame) -8 2)))) + (set-frame-position (selected-frame) -8 2)) ((= pw 1680) ;; we're on a big external monitor (font-menu-set-font nil nil 10) @@ -468,8 +453,8 @@ (ht-custom-size) ;;; make dired list directories first -;(defadvice dired-insert-directory (before my-dired-insert-directory -; (dir-or-list switches &optional wildcard full-p)) -; (setq switches (concat switches " --group-directories-first"))) +(defadvice dired-insert-directory (before my-dired-insert-directory + (dir-or-list switches &optional wildcard full-p)) + (setq switches (concat switches " --group-directories-first"))) -;(ad-activate 'dired-insert-directory) +(ad-activate 'dired-insert-directory)