summaryrefslogtreecommitdiff
path: root/bin/flt/m
blob: 9611cd1951d0f82cb84ec29e9cc494a98e80fe88 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
#!/bin/sh

# m -- switch first and last line (move)

read first
mid=
last=
while read line; do
	mid="$mid$last"
	last="
$line"
done
echo "$last" | tr -d '
'
echo "$mid"
echo "$first"