Ticket #180: patch-vfs.patch
File patch-vfs.patch, 7.2 KB (added by styx, 15 years ago) |
---|
-
configure.ac
diff -urNb mc/configure.ac mc-modifs/configure.ac
old new 607 607 vfs/extfs/mailfs 608 608 vfs/extfs/patchfs 609 609 vfs/extfs/rpms 610 vfs/extfs/uace 610 611 vfs/extfs/ualz 611 612 vfs/extfs/uar 613 vfs/extfs/uarc 612 614 vfs/extfs/uarj 615 vfs/extfs/uc1541 613 616 vfs/extfs/uha 614 617 vfs/extfs/ulha 615 618 vfs/extfs/urar -
lib/mc.ext.in
diff -urNb mc/lib/mc.ext.in mc-modifs/lib/mc.ext.in
old new 512 512 regex/\.(rexx?|cmd)$ 513 513 Open=rexx %f %{Enter parameters};echo "Press ENTER";read y 514 514 515 # Disk images for Commodore computers (VIC20, C64, C128) 516 regex/\.(d64|D64)$ 517 Open=%cd %p#uc1541 518 View=%view{ascii} c1541 %f -list 519 Extract=c1541 %f -extract 520 515 521 516 522 ### Plain compressed files ### 517 523 524 # ace 525 regex/\.(ace|ACE)$ 526 Open=%cd %p#uace 527 View=%view{ascii} unace l %f 528 Extract=unace x %f 529 530 # arc 531 regex/\.(arc|ARC)$ 532 Open=%cd %p#uarc 533 View=%view{ascii} arc l %f 534 Extract=arc x %f '*' 535 Extract (with flags)=I=%{Enter any Arc flags:}; if test -n "$I"; then arc x $I %f; fi 536 518 537 # zip 519 538 type/^([Zz][Ii][Pp])\ archive 520 539 Open=%cd %p#uzip -
vfs/extfs/extfs.ini
diff -urNb mc/vfs/extfs/extfs.ini mc-modifs/vfs/extfs/extfs.ini
old new 11 11 ualz 12 12 # For arj usage you need a special patch to unarj (see unarj.diff) 13 13 uarj 14 uarc 15 uace 14 16 15 17 # ar is used for static libraries 16 18 uar … … 28 30 # Hewlett Packard calculator 29 31 hp48: 30 32 33 # Commodore 64/128 d64/D64 files 34 uc1541 35 31 36 # Break patches into chunks 32 37 patchfs 33 38 -
vfs/extfs/Makefile.am
diff -urNb mc/vfs/extfs/Makefile.am mc-modifs/vfs/extfs/Makefile.am
old new 21 21 mailfs.in \ 22 22 patchfs.in \ 23 23 rpms.in \ 24 uace.in \ 24 25 ualz.in \ 25 26 uar.in \ 27 uarc.in \ 26 28 uarj.in \ 29 uc1541.in \ 27 30 uha.in \ 28 31 ulha.in \ 29 32 urar.in \ … … 45 48 mailfs \ 46 49 patchfs \ 47 50 rpms \ 51 uace \ 48 52 ualz \ 49 53 uar \ 54 uarc \ 50 55 uarj \ 56 uc1541 \ 51 57 uha \ 52 58 ulha \ 53 59 urar \ -
vfs/extfs/uace.in
diff -urNb mc/vfs/extfs/uace.in mc-modifs/vfs/extfs/uace.in
old new 1 #! /bin/sh 2 3 # 4 # ACE Virtual filesystem executive v0.1 5 # Works with unace v2.5 6 7 # Copyright (C) 2008 Jacques Pelletier 8 # May be distributed under the terms of the GNU Public License 9 # <jpelletier@ieee.org> 10 # 11 12 # Define your awk 13 AWK=gawk 14 # Define which archiver you are using with appropriate options 15 ACE_LIST="unace l" 16 ACE_GET="unace x" 17 # ACE_PUT="unace ?" not available 18 19 # The 'list' command executive 20 21 # Unace: DD.MM.YY HH.MM packed size ratio file 22 # ls: 23 mc_ace_fs_list() 24 { 25 $ACE_LIST "$1" | gawk -v uid=${UID-0} ' 26 BEGIN { Month="JanFebMarAprMayJunJulAugSepOctNovDec" } 27 /%/ { 28 split($1,date,".") 29 30 if (date[3] > 50) 31 date[3]=date[3] + 1900 32 else 33 date[3]=date[3] + 2000 34 35 printf "-rw-r--r-- 1 %-8d %-8d %8d %s %2d %4d %s %s\n", uid, 0, $3, substr(Month,3*(date[2]-1)+1,3),date[1],date[3], $2, $6 36 }' 2>/dev/null 37 exit 0 38 } 39 40 # Command: copyout archivename storedfilename extractto 41 mc_ace_fs_copyout() 42 { 43 $ACE_GET "$1" "$2" > /dev/null 2>&1 44 mv "$2" "$3" 45 } 46 47 # The main routine 48 umask 077 49 50 cmd="$1" 51 shift 52 53 case "$cmd" in 54 list) mc_ace_fs_list "$@" ;; 55 copyout) mc_ace_fs_copyout "$@" ;; 56 *) exit 1 ;; 57 esac 58 exit 0 -
vfs/extfs/uarc.in
diff -urNb mc/vfs/extfs/uarc.in mc-modifs/vfs/extfs/uarc.in
old new 1 #! /bin/sh 2 3 # 4 # ARC Virtual filesystem executive 5 # Copyright (C) 2008 Jacques Pelletier 6 # May be distributed under the terms of the GNU Public License 7 # <jpelletier@ieee.org> 8 # 9 10 # Define your awk 11 AWK=gawk 12 # Define which archiver you are using with appropriate options 13 ARC_LIST="arc v" 14 ARC_GET="arc x" 15 ARC_PUT="arc a" 16 ARC_DEL="arc d" 17 18 # The 'list' command executive 19 20 mc_arc_fs_list() 21 { 22 $ARC_LIST "$1" | gawk -v uid=${UID-0} ' 23 BEGIN { } 24 /^Name/ { next } 25 /===/ { next } 26 /^Total/ { next } 27 { 28 if ($8 > 50) 29 $8=$8 + 1900 30 else 31 $8=$8 + 2000 32 33 split($9, a, ":") 34 35 # convert AM/PM to 00-23 36 if (a[2] ~ /a$|p$/) 37 { 38 if (a[2] ~ /p$/) 39 a[1] = a[1]+12 40 41 a[2]=substr(a[2],1,2) 42 } 43 44 printf "-rw-r--r-- 1 %-8d %-8d %8d %s %2d %4d %02d:%02d %s\n", uid, 0, $2, $7, $6, $8, a[1], a[2], $1 45 }' 2>/dev/null 46 exit 0 47 } 48 49 # Command: copyout archivename storedfilename extractto 50 mc_arc_fs_copyout() 51 { 52 $ARC_GET "$1" "$2" 2> /dev/null 53 mv "$2" "$3" 54 } 55 56 # Command: copyin archivename storedfilename sourcefile 57 mc_arc_fs_copyin() 58 { 59 mv "$3" "$2" 60 $ARC_PUT "$1" "$2" 2> /dev/null 61 } 62 63 # Command: rm archivename storedfilename 64 mc_arc_fs_rm() 65 { 66 $ARC_DEL "$1" "$2" 2> /dev/null 67 } 68 69 # The main routine 70 umask 077 71 72 cmd="$1" 73 shift 74 75 case "$cmd" in 76 list) mc_arc_fs_list "$@" ;; 77 copyout) mc_arc_fs_copyout "$@" ;; 78 copyin) mc_arc_fs_copyin "$@" ;; 79 rm) mc_arc_fs_rm "$@" ;; 80 *) exit 1 ;; 81 esac 82 exit 0 -
vfs/extfs/uc1541.in
diff -urNb mc/vfs/extfs/uc1541.in mc-modifs/vfs/extfs/uc1541.in
old new 1 #! /bin/sh 2 3 # 4 # UC1541 Virtual filesystem executive v0.1 5 6 # This is for accessing disk image files for the Commodore VIC20/C64/C128 7 # It requires the utility c1541 that comes bundled with Vice, the emulator 8 # for the VIC20, C64, C128 and other computers made by Commodore. 9 10 # Copyright (C) 2008 Jacques Pelletier 11 # May be distributed under the terms of the GNU Public License 12 # <jpelletier@ieee.org> 13 # 14 15 # Define your awk 16 AWK=gawk 17 # Define which archiver you are using with appropriate options 18 C1541="c1541" 19 20 # There are no time stamps in the disk image, so a bogus timestamp is displayed 21 mc_c1541_fs_list() 22 { 23 $C1541 "$1" -list | gawk -v uid=${UID-0} ' 24 BEGIN { FS = "\"" } 25 /No LINES!/ { next } 26 /BLOCKS FREE/ { next } 27 $1 == 0 { next } 28 { 29 printf "-rw-r--r-- 1 %-8d %-8d %8d Jan 01 1980 00:00 %s\n", uid, 0, $1 * 256, $2 30 }' 2>/dev/null 31 } 32 33 # Command: copyout archivename storedfilename extractto 34 # -read image 1541name [fsname] 35 mc_c1541_fs_copyout() 36 { 37 $C1541 "$1" -read "$2" 2> /dev/null 38 mv "$2" "$3" 39 } 40 41 # FIXME mc can't do chown of the file inside the archive 42 # Command: copyin archivename storedfilename sourcefile 43 # -write image fsname [1541name] 44 mc_c1541_fs_copyin() 45 { 46 mv "$3" "$2" 47 $C1541 "$1" -write "$2" 2> /dev/null 48 } 49 50 # Command: rm archivename storedfilename 51 # -delete image files 52 mc_c1541_fs_rm() 53 { 54 $C1541 "$1" -delete "$2" 2> /dev/null 55 } 56 57 # The main routine 58 umask 077 59 60 cmd="$1" 61 shift 62 63 case "$cmd" in 64 list) mc_c1541_fs_list "$@" ;; 65 copyout) mc_c1541_fs_copyout "$@" ;; 66 # copyin) mc_c1541_fs_copyin "$@" ;; 67 rm) mc_c1541_fs_rm "$@" ;; 68 *) exit 1 ;; 69 esac 70 exit 0