2
1

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.

ShellScript メモ

Last updated at Posted at 2018-11-26

たまにつかうシェルスクリプトのメモ

実行中ファイルの特定
lost [file]
kill [pid]
play_c.sh
# !/bin/sh

if [ $# -gt 0 ]; then
		gcc $1.c -o $1
		./$1
	
else
	echo "1つ以上の引数を渡してください"
fi
play_java.sh
# !/bin/sh
if [ $# -gt 0 ]; then
  javac $1.java
  java $1
else
  echo "1つ以上の引数を渡してください"
fi
for i in *.txt
do
	mv $i ${i%.txt}.csv
	nkf -s ${i%.txt}.csv >> ${i%.txt}s.csv
done
# %,%%右端から最短の、最長のパターン一致を削除
## ,##左端から最短の、最長のパターン一致を削除
2
1
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
1

Delete article

Deleted articles cannot be recovered.

Draft of this article would be also deleted.

Are you sure you want to delete this article?