浏览代码

chore(nml): update script to delete all nsg jobs

Ankur Sinha (Ankur Sinha Gmail) 10 月之前
父节点
当前提交
dd815fcd77
共有 1 个文件被更改,包括 17 次插入0 次删除
  1. 17 0
      NeuroML2/clean-nsg-jobs.sh

+ 17 - 0
NeuroML2/clean-nsg-jobs.sh

@@ -0,0 +1,17 @@
+#!/bin/bash
+
+# Copyright 2023 Ankur Sinha
+# Author: Ankur Sinha <sanjay DOT ankur AT gmail DOT com> 
+# File : 
+#
+
+
+nsgr_job -l | cut -f2 -d ' ' > joblist.txt
+
+while IFS="" read -r line ; do
+    echo "Deleting job: ${line}"
+    nsgr_job -j ${line} -r
+done < joblist.txt
+
+echo "All jobs deleted"
+echo "Please delete joblist.txt"