2
2

Delete article

Deleted articles cannot be recovered.

Draft of this article would be also deleted.

Are you sure you want to delete this article?

More than 5 years have passed since last update.

bash

2
Last updated at Posted at 2015-10-23

shell script

while loop

  • sample1
while read line
do
echo mv $(echo $line | awk '{print $1}') $(echo $line | awk '{print $2}')
done << EOF
1 1
2 3
3 5
4 7
5 9
6 11
7 12
8 13
9 14
10 15
11 16
12 17
15 20
16 21
17 22
18 23
19 24
20 25
EOF

command prompt

show current git branch

parse_git_branch() { 
    git branch 2> /dev/null | sed -e '/^[^*]/d' -e 's/* (.*)/(1)/' 
}
 
export PS1="[33[00m]u@h[33[01;34m] W [33[31m]$(parse_git_branch) [33[00m]$[33[00m] " 
2
2
0

Register as a new user and use Qiita more conveniently

  1. You get articles that match your needs
  2. You can efficiently read back useful information
  3. You can use dark theme
What you can do with signing up
2
2

Delete article

Deleted articles cannot be recovered.

Draft of this article would be also deleted.

Are you sure you want to delete this article?