File tree 3 files changed +52
-0
lines changed
3 files changed +52
-0
lines changed Original file line number Diff line number Diff line change
1
+ #! /bin/sh
2
+
3
+ # apt-get install gvfs-bin
4
+
5
+ if [ ! -f " $1 " ] ; then
6
+ echo " $0 <file>"
7
+ exit 1
8
+ fi
9
+
10
+ F=` basename " $1 " `
11
+ D=` dirname " $1 " `
12
+ N=" ${D} /_${F} "
13
+
14
+ echo " ${F} " | egrep -q ' ^_'
15
+ if [ " $? " -eq " 1" ]; then
16
+ mv " $1 " " ${N} "
17
+ else
18
+ N=" $1 "
19
+ fi
20
+
21
+ gvfs-set-attribute -t stringv " ${N} " metadata::emblems generic
22
+
23
+ exec vlc --file-caching 4000 " ${N} "
24
+
Original file line number Diff line number Diff line change
1
+ #! /bin/sh
2
+
3
+ # apt-get install gvfs-bin nautilus-actions
4
+
5
+ CMD=" false"
6
+
7
+ if [ -z " $1 " ]; then
8
+ set -- " ."
9
+ fi
10
+
11
+ for arg in " $@ " ; do
12
+ if [ -d " ${arg} " ]; then
13
+ cd " ${arg} "
14
+ CMD=" ls"
15
+ elif [ -f " ${arg} " ]; then
16
+ CMD=" ls ${arg} "
17
+ fi
18
+
19
+ eval " ${CMD} " | while read file; do
20
+ D=` dirname " ${file} " `
21
+ F=` basename " ${file} " | sed ' s/^_//' `
22
+ N=" ${D} /${F} "
23
+ if [ " ./${file} " != " ${N} " ]; then
24
+ mv " ${file} " " ${N} "
25
+ fi
26
+ gvfs-set-attribute -t unset " ${N} " metadata::emblems
27
+ done
28
+ done
You can’t perform that action at this time.
0 commit comments