mirror of
https://github.com/A2osX/A2osX.git
synced 2024-07-14 04:29:02 +00:00
Kernel version 0.9 : CP/MV/RM, bug fix in RM <DIR>
This commit is contained in:
parent
f818be145b
commit
76d1721df4
BIN
A2OSX.BOOT.po
BIN
A2OSX.BOOT.po
Binary file not shown.
BIN
A2OSX.SRC.po
BIN
A2OSX.SRC.po
Binary file not shown.
@ -85,19 +85,17 @@ CS.INIT >SYSCALL GetArgC
|
|||||||
lda (pData),y
|
lda (pData),y
|
||||||
*--------------------------------------
|
*--------------------------------------
|
||||||
.DO X.COPY.TO.DEST=1
|
.DO X.COPY.TO.DEST=1
|
||||||
*--------------------------------------
|
|
||||||
bne .5 Already have a Src dir...
|
bne .5 Already have a Src dir...
|
||||||
.ELSE
|
.ELSE
|
||||||
bne .99
|
bne .99
|
||||||
.FIN
|
.FIN
|
||||||
*--------------------------------------
|
*--------------------------------------
|
||||||
>LDYA ZPPtr1
|
>LDYA ZPPtr1
|
||||||
jsr InitSrcDirYA
|
jsr InitSrcDirPatYA
|
||||||
bcc .1 success, scan for any other args
|
bcc .1 success, scan for any other args
|
||||||
rts
|
rts
|
||||||
*--------------------------------------
|
*--------------------------------------
|
||||||
.DO X.COPY.TO.DEST=1
|
.DO X.COPY.TO.DEST=1
|
||||||
*--------------------------------------
|
|
||||||
.5 ldy #hDstBasePath
|
.5 ldy #hDstBasePath
|
||||||
lda (pData),y
|
lda (pData),y
|
||||||
bne .99 we already have a second arg....error!
|
bne .99 we already have a second arg....error!
|
||||||
@ -113,7 +111,6 @@ CS.INIT >SYSCALL GetArgC
|
|||||||
beq .99 , no src ? ERROR
|
beq .99 , no src ? ERROR
|
||||||
*--------------------------------------
|
*--------------------------------------
|
||||||
.DO X.COPY.TO.DEST=1
|
.DO X.COPY.TO.DEST=1
|
||||||
*--------------------------------------
|
|
||||||
ldy #hDstBasePath
|
ldy #hDstBasePath
|
||||||
lda (pData),y
|
lda (pData),y
|
||||||
bne .8 we also have a Dst folder
|
bne .8 we also have a Dst folder
|
||||||
@ -153,15 +150,13 @@ CS.RUN >SYSCALL GetC
|
|||||||
bmi .8
|
bmi .8
|
||||||
*--------------------------------------
|
*--------------------------------------
|
||||||
.1 .DO X.COPY.TO.DEST=1
|
.1 .DO X.COPY.TO.DEST=1
|
||||||
*--------------------------------------
|
|
||||||
ldy #bCopy
|
ldy #bCopy
|
||||||
lda (pData),y
|
lda (pData),y
|
||||||
bpl .2
|
bpl .2
|
||||||
jmp CS.RUN.Copy
|
jmp CS.RUN.Copy
|
||||||
.FIN
|
.FIN
|
||||||
*--------------------------------------
|
*--------------------------------------
|
||||||
.2 .DO X.DELETE.SOURCE
|
.2 .DO X.DELETE.SOURCE=1
|
||||||
*--------------------------------------
|
|
||||||
ldy #hToDelete
|
ldy #hToDelete
|
||||||
lda (pData),y
|
lda (pData),y
|
||||||
beq .3
|
beq .3
|
||||||
@ -198,13 +193,8 @@ CS.RUN >SYSCALL GetC
|
|||||||
|
|
||||||
.9 jsr LeaveSubDir
|
.9 jsr LeaveSubDir
|
||||||
bcs .99
|
bcs .99
|
||||||
|
|
||||||
ldy #bRecurse
|
|
||||||
lda (pData),y
|
|
||||||
bpl .8
|
|
||||||
*--------------------------------------
|
*--------------------------------------
|
||||||
.DO X.DELETE.SOURCE=1
|
.DO X.DELETE.SOURCE=1
|
||||||
*--------------------------------------
|
|
||||||
ldy #hSrcBasePath
|
ldy #hSrcBasePath
|
||||||
jsr CS.RUN.GetBasePath
|
jsr CS.RUN.GetBasePath
|
||||||
>SYSCALL RemoveYA
|
>SYSCALL RemoveYA
|
||||||
@ -212,6 +202,10 @@ CS.RUN >SYSCALL GetC
|
|||||||
bcs .99
|
bcs .99
|
||||||
.FIN
|
.FIN
|
||||||
*--------------------------------------
|
*--------------------------------------
|
||||||
|
ldy #bRecurse
|
||||||
|
lda (pData),y
|
||||||
|
bpl .8
|
||||||
|
|
||||||
jsr BasePath..
|
jsr BasePath..
|
||||||
|
|
||||||
.8 clc
|
.8 clc
|
||||||
@ -243,11 +237,7 @@ CS.RUN.DEV >PUSHW ZPPtr1
|
|||||||
.8 clc
|
.8 clc
|
||||||
.9 rts
|
.9 rts
|
||||||
*--------------------------------------
|
*--------------------------------------
|
||||||
CS.RUN.DIR ldy #bRecurse
|
CS.RUN.DIR ldy #1
|
||||||
lda (pData),y
|
|
||||||
bpl .8
|
|
||||||
|
|
||||||
ldy #1
|
|
||||||
lda (ZPPtr1),y
|
lda (ZPPtr1),y
|
||||||
cmp #'.'
|
cmp #'.'
|
||||||
beq .8
|
beq .8
|
||||||
@ -256,18 +246,32 @@ CS.RUN.DIR ldy #bRecurse
|
|||||||
bcs .9
|
bcs .9
|
||||||
*--------------------------------------
|
*--------------------------------------
|
||||||
.DO X.COPY.TO.DEST=1
|
.DO X.COPY.TO.DEST=1
|
||||||
*--------------------------------------
|
|
||||||
ldy #hDstBasePath
|
ldy #hDstBasePath
|
||||||
jsr CS.RUN.GetFilePath
|
jsr CS.RUN.GetFilePath
|
||||||
|
|
||||||
>LDYAI UsrBuf256
|
>LDYAI UsrBuf256
|
||||||
>SYSCALL MKDirYA
|
>SYSCALL MKDirYA
|
||||||
jsr CS.RUN.CheckErr
|
jsr CS.RUN.CheckErr
|
||||||
|
bcs .9
|
||||||
.FIN
|
.FIN
|
||||||
*--------------------------------------
|
*--------------------------------------
|
||||||
.1 >LDYA ZPPtr1
|
ldy #bRecurse
|
||||||
jmp EnterSubDirYA
|
lda (pData),y
|
||||||
|
bpl .1
|
||||||
|
|
||||||
|
>LDYA ZPPtr1
|
||||||
|
jmp EnterSubDirYA
|
||||||
|
*--------------------------------------
|
||||||
|
.1 .DO X.DELETE.SOURCE=1
|
||||||
|
|
||||||
|
ldy #hSrcBasePath
|
||||||
|
jsr CS.RUN.GetFilePath
|
||||||
|
>LDYAI UsrBuf256
|
||||||
|
>SYSCALL RemoveYA
|
||||||
|
jsr CS.RUN.CheckErr
|
||||||
|
bcs .9
|
||||||
|
.FIN
|
||||||
|
*--------------------------------------
|
||||||
.8 clc
|
.8 clc
|
||||||
.9 rts
|
.9 rts
|
||||||
*--------------------------------------
|
*--------------------------------------
|
||||||
@ -275,27 +279,24 @@ CS.RUN.FILE jsr CS.RUN.PrintFile
|
|||||||
bcs .9
|
bcs .9
|
||||||
*--------------------------------------
|
*--------------------------------------
|
||||||
.DO X.COPY.TO.DEST=1
|
.DO X.COPY.TO.DEST=1
|
||||||
*--------------------------------------
|
|
||||||
jsr CS.RUN.CopyStart
|
jsr CS.RUN.CopyStart
|
||||||
bcs .9
|
bcs .9
|
||||||
rts
|
|
||||||
.FIN
|
.FIN
|
||||||
*--------------------------------------
|
*--------------------------------------
|
||||||
.DO X.DELETE.SOURCE=1
|
.DO X.DELETE.SOURCE=1
|
||||||
*--------------------------------------
|
|
||||||
ldy #hSrcBasePath
|
ldy #hSrcBasePath
|
||||||
jsr CS.RUN.GetFilePath
|
jsr CS.RUN.GetFilePath
|
||||||
>LDYAI UsrBuf256
|
>LDYAI UsrBuf256
|
||||||
>SYSCALL NewPStrYA
|
>SYSCALL NewPStrYA
|
||||||
bcs .9
|
bcs .99
|
||||||
txa
|
txa
|
||||||
ldy #hToDelete
|
ldy #hToDelete
|
||||||
sta (pData),y
|
sta (pData),y
|
||||||
|
|
||||||
.FIN
|
.FIN
|
||||||
*--------------------------------------
|
*--------------------------------------
|
||||||
.9 jsr CS.RUN.CheckErr
|
|
||||||
rts
|
rts
|
||||||
|
.9 jsr CS.RUN.CheckErr
|
||||||
|
.99 rts
|
||||||
*--------------------------------------
|
*--------------------------------------
|
||||||
CS.RUN.PrintDir ldy #hDstBasePath
|
CS.RUN.PrintDir ldy #hDstBasePath
|
||||||
lda (pData),y
|
lda (pData),y
|
||||||
@ -331,7 +332,6 @@ CS.RUN.PrintFile
|
|||||||
rts
|
rts
|
||||||
*--------------------------------------
|
*--------------------------------------
|
||||||
.DO X.COPY.TO.DEST=1
|
.DO X.COPY.TO.DEST=1
|
||||||
*--------------------------------------
|
|
||||||
CS.RUN.CopyStart
|
CS.RUN.CopyStart
|
||||||
ldy #S.STAT.P.AUXTYPE+1
|
ldy #S.STAT.P.AUXTYPE+1
|
||||||
>PUSHB (ZPPtr2),y
|
>PUSHB (ZPPtr2),y
|
||||||
@ -449,11 +449,9 @@ CS.RUN.CopyEnd ldy #hSrcFile
|
|||||||
beq CS.RUN.CheckErr
|
beq CS.RUN.CheckErr
|
||||||
sec
|
sec
|
||||||
jmp CS.RUN.CheckErr
|
jmp CS.RUN.CheckErr
|
||||||
*--------------------------------------
|
|
||||||
.FIN
|
.FIN
|
||||||
*--------------------------------------
|
*--------------------------------------
|
||||||
.DO X.DELETE.SOURCE=1
|
.DO X.DELETE.SOURCE=1
|
||||||
*--------------------------------------
|
|
||||||
CS.RUN.Delete pha
|
CS.RUN.Delete pha
|
||||||
lda #0
|
lda #0
|
||||||
sta (pData),y
|
sta (pData),y
|
||||||
@ -461,7 +459,6 @@ CS.RUN.Delete pha
|
|||||||
>SYSCALL GetMemPtrA
|
>SYSCALL GetMemPtrA
|
||||||
>SYSCALL RemoveYA
|
>SYSCALL RemoveYA
|
||||||
jmp CS.RUN.CheckErr
|
jmp CS.RUN.CheckErr
|
||||||
*--------------------------------------
|
|
||||||
.FIN
|
.FIN
|
||||||
*--------------------------------------
|
*--------------------------------------
|
||||||
CS.RUN.CheckErr bcs .1
|
CS.RUN.CheckErr bcs .1
|
||||||
@ -508,7 +505,24 @@ CS.DOEVENT sec
|
|||||||
CS.QUIT jsr LeaveSubDir
|
CS.QUIT jsr LeaveSubDir
|
||||||
bcc CS.QUIT
|
bcc CS.QUIT
|
||||||
|
|
||||||
ldy #hFilter
|
ldy #hToDelete
|
||||||
|
lda (pData),y
|
||||||
|
beq .1
|
||||||
|
>SYSCALL FreeMemA
|
||||||
|
|
||||||
|
.1 ldy #bCopy
|
||||||
|
lda (pData),y
|
||||||
|
bpl .2
|
||||||
|
|
||||||
|
ldy #hSrcFile
|
||||||
|
lda (pData),y
|
||||||
|
>SYSCALL FCloseA
|
||||||
|
|
||||||
|
ldy #hDstFile
|
||||||
|
lda (pData),y
|
||||||
|
>SYSCALL FCloseA
|
||||||
|
|
||||||
|
.2 ldy #hFilter
|
||||||
lda (pData),y
|
lda (pData),y
|
||||||
beq .8
|
beq .8
|
||||||
>SYSCALL FreeMemA
|
>SYSCALL FreeMemA
|
||||||
@ -518,5 +532,5 @@ CS.QUIT jsr LeaveSubDir
|
|||||||
*--------------------------------------
|
*--------------------------------------
|
||||||
MAN
|
MAN
|
||||||
SAVE BIN/X.CPMVRM.S
|
SAVE BIN/X.CPMVRM.S
|
||||||
LOAD BIN/CP.S
|
LOAD BIN/RM.S
|
||||||
ASM
|
ASM
|
||||||
|
@ -315,7 +315,6 @@ EnterSubDirYA >STYA ZPPtr2 save SUBDIR for StrCat
|
|||||||
jsr EnterSubDirYA.1
|
jsr EnterSubDirYA.1
|
||||||
.FIN
|
.FIN
|
||||||
|
|
||||||
|
|
||||||
.9 rts
|
.9 rts
|
||||||
|
|
||||||
EnterSubDirYA.1 lda (pData),y
|
EnterSubDirYA.1 lda (pData),y
|
||||||
|
Loading…
Reference in New Issue
Block a user