浏览代码

Some common shell scripts too

Getty Ritter 9 年之前
父节点
当前提交
7db2506c3c
共有 3 个文件被更改,包括 19 次插入0 次删除
  1. 5 0
      scripts/as-tmp
  2. 7 0
      scripts/ff-here
  3. 7 0
      scripts/surf-here

+ 5 - 0
scripts/as-tmp

@@ -0,0 +1,5 @@
+#!/bin/sh
+
+FILENAME=$(mktemp)
+cat >$FILENAME
+echo $FILENAME

+ 7 - 0
scripts/ff-here

@@ -0,0 +1,7 @@
+#!/bin/sh
+
+if [[ "$1" = /* ]]; then
+	firefox file://$1
+else
+	firefox file://$(pwd)/$1
+fi

+ 7 - 0
scripts/surf-here

@@ -0,0 +1,7 @@
+#!/bin/sh
+
+if [[ "$1" = /* ]]; then
+	surf file://$1
+else
+	surf file://$(pwd)/$1
+fi