mirror of
https://github.com/MidnightCommander/mc
synced 2024-12-23 21:06:52 +03:00
36d59acf97
fixed configure.ac added lib/vfs/mc-vfs/fish/Makefile.am lib/vfs/mc-vfs/fishdef.h moved lib/vfs/mc-vfs/fish/README.fish fixed lib/vfs/mc-vfs/Makefile.am added external scripts in lib/vfs/mc-vfs/fish/ * ls - get gile list * mkdir - make directory * rmdir - remove directory * unlink - delete file * chown - change owner/group of file * chmod - change mode of file * mv - move file * ln - make symlink * hardlink - make hardlink * send - copy file to target host * append - append file to target host (if exists) * get - copy file from target host * info - return resalts of scan remote host (have: perl, sed, awk, etc) Signed-off-by: Andrew Borodin <aborodin@vmail.ru> Signed-off-by: Ilia Maslakov <il.smind@gmail.com> fish.c: optimization and code cleanup Signed-off-by: Andrew Borodin <aborodin@vmail.ru> optimization of FISH environment variables. Signed-off-by: Andrew Borodin <aborodin@vmail.ru>
19 lines
482 B
Plaintext
Executable File
19 lines
482 B
Plaintext
Executable File
#APPE $FISH_FILESIZE $FISH_FILENAME
|
|
echo "### 001"
|
|
FILENAME="/$FISH_FILENAME"
|
|
res=`exec 3>&1
|
|
(
|
|
head -c $FISH_FILESIZE -q - || echo DD >&3
|
|
) 2>/dev/null | (
|
|
cat > "${FILENAME}"
|
|
cat > /dev/null
|
|
)`; [ "$res" = DD ] && {
|
|
> "${FILENAME}"
|
|
while [ $FISH_FILESIZE -gt 0 ]
|
|
do
|
|
cnt=`expr \\( $FISH_FILESIZE + 255 \\) / 256`
|
|
n=`dd bs=256 count=$cnt | tee -a "${FILENAME}" | wc -c`
|
|
FISH_FILESIZE=`expr $FISH_FILESIZE - $n`
|
|
done
|
|
}; echo "### 200"
|