mirror of
https://github.com/a2stuff/prodos-path.git
synced 2024-12-27 13:29:22 +00:00
4bdb0808a2
This is used by the GS/OS Finder to conceal FINDER.DATA files. Documented in "Exploring GS/OS and ProDOS 8" by Gary B. Little. BASIC.SYSTEM's CAT/CATALOG are unaware of this, so the files are still listed. Note that the command is named "UNHIDE" rather than "SHOW" as that sounds like a command to display file contents or something.
69 lines
1.6 KiB
ArmAsm
69 lines
1.6 KiB
ArmAsm
;;; ============================================================
|
|
;;;
|
|
;;; UNHIDE - Mark a file as not invisible
|
|
;;;
|
|
;;; Usage: UNHIDE filename[,S#][,D#]
|
|
;;;
|
|
;;; * filename can be relative or absolute path
|
|
;;;
|
|
;;; ============================================================
|
|
|
|
.include "apple2.inc"
|
|
.include "more_apple2.inc"
|
|
.include "prodos.inc"
|
|
|
|
;;; ============================================================
|
|
|
|
.org $4000
|
|
|
|
;; NOTE: Assumes XLEN is set by PATH
|
|
|
|
;; Point BI's parser at the command execution routine.
|
|
lda #<execute
|
|
sta XTRNADDR
|
|
lda #>execute
|
|
sta XTRNADDR+1
|
|
|
|
;; Mark command as external (zero).
|
|
lda #0
|
|
sta XCNUM
|
|
|
|
;; Set accepted parameter flags
|
|
|
|
;; Filename
|
|
lda #PBitsFlags::FN1
|
|
sta PBITS
|
|
|
|
;; Slot & Drive handling
|
|
lda #PBitsFlags::SD
|
|
sta PBITS+1
|
|
|
|
clc ; Success (so far)
|
|
rts1: rts ; Return to BASIC.SYSTEM
|
|
|
|
;;; ============================================================
|
|
|
|
execute:
|
|
;; Get the existing file info
|
|
lda #$A
|
|
sta SSGINFO
|
|
lda #GET_FILE_INFO
|
|
jsr GOSYSTEM
|
|
bcs rts1
|
|
|
|
;;; --------------------------------------------------
|
|
|
|
;; Set invisible bit
|
|
lda FIACESS
|
|
and #<(~ACCESS_I)
|
|
sta FIACESS
|
|
|
|
;; Set new file info
|
|
lda #$7
|
|
sta SSGINFO
|
|
|
|
lda #SET_FILE_INFO
|
|
jmp GOSYSTEM
|
|
|
|
;;; --------------------------------------------------
|