This commit is contained in:
Patrick Kloepfer 2021-04-15 16:44:05 -04:00
parent 24ff6f27c0
commit f7b1fa848d
20 changed files with 567 additions and 67 deletions

Binary file not shown.

Binary file not shown.

Binary file not shown.

Binary file not shown.

Binary file not shown.

View File

@ -1,9 +0,0 @@
NEW
PREFIX
AUTO 4,1
#!/BIN/SH
#
# HELP
#
MAN
TEXT /MAKE/USR/SHARE/ADMIN/HELP

29
ADMIN/adm.txt Normal file
View File

@ -0,0 +1,29 @@
NEW
PREFIX
AUTO 4,1
#!/bin/sh
#
# This is the Main ADM script
# It is used to call all other A2osX Domain Manager (ADM) scripts
#
# Check to make sure SysAdmin is installed
set sapath = ${BOOT}usr/share/adm/
if ![ -D ${sapath} ]
echo "\nA2osX Domain Manager support files not installed"
echo "Please update your A2osX installation\n"
exit
fi
if [ $# = 0 ]
echo "\nNo Command or Argument specified"
echo "try \e[7mhelp adm\e[0m or \e[7madm commands\e[0m\n"
exit
fi
pushp $sapath
if [ -f $1 ]
$1 $2 $3 $4 $5 $6 $7 $8 $9
else
echo sysadm $1 command not found
fi
popd
MAN
TEXT /MAKE/usr/share/adm/adm

72
ADMIN/update.txt Normal file
View File

@ -0,0 +1,72 @@
NEW
PREFIX
AUTO 4,1
#!/bin/sh
#
# This is the ADM Update script
# It is used to update the current installation to the most
# recent version over the internet using httpget
#
check that ${BOOT}tmp exists and if not create it
check again? if so fail? or RC check the MD/mkdir cmd?
check for existing version file, if not there, set to A2osX/0.94/1111/
check for net loaded? do deep check? or just try to ping to update.a2osx.net?
set netcheck = `ping -1 update.a2osx.net 2>/dev/null`
if [$netcheck = "TCP/IP Not Loaded/Configured."]
echo Network Not Loaded
exit
fi
httpget update.a2osx.net -U latest -O ${BOOT}tmp/latest
compare latest and new
if newer...
httpget update.a2osx.net -U update.${build} -O ${BOOT}tmp/update
unpak
fix stuff up like KMs
remove tmp files
should any of these steps be logged somewhere?
set helppath = ${BOOT}usr/share/help
if ![ -D ${helppath} ]
echo "\nA2osX Help files are not installed"
echo "Please update your A2osX installation\n"
exit
fi
switch $#
case 0
echo "\nNo Help Argument specified"
echo "try \e[7madm help help\e[0m for more command usage\n"
break
case 1
if [ $1 = "list" ] OR [ $1 = "LIST" ]
ls -R ${helppath}
exit
fi
if [ -f $1 ]
set helpfile = ${helppath} + "/" + $1
else
echo "Help is not available for ${1}"
echo "Try \e[7mhelp list\e[0m for a list of help topics\n"
exit
fi
break
case 2
#check first that subdir exists then append full name and check that
break
case 3
#check first that subdir and subdir exists then append full name and check that
break
default
#we assume no more then 3 levels
#so this must be an error or should we just process this as same for case 3 and ignore 4+
end
MAN
TEXT /MAKE/usr/share/adm/update

89
CTESTS/CTEST.txt Normal file
View File

@ -0,0 +1,89 @@
NEW
PREFIX
AUTO 4,1
#!/bin/csh
// This is a comment....
puts(argv[1]);
exit
puts("puts: test 'const char *' string.");
struct tag_test {
int cnt;
float f;
tag_test *next;
};
long L1=3;
long L2=5;
long L3=7;
printf("L1=%L, L2=%L, L3=%L\r\n", L1, L2, L3);
L3=L1*L2+1;
printf("L3=L1*L2+1:L1=%L, L2=%L, L3=%L\r\n", L1, L2, L3);
L3=L1+5*9;
printf("L3=L1+5*9:L1=%L, L2=%L, L3=%L\r\n", L1, L2, L3);
L3=(L1+5)*L2+10;
printf("L3=(L1+5)*L2+10:L1=%L, L2=%L, L3=%L\r\n", L1, L2, L3);
#define PI 3.14159265
float f = PI / 3;
printf("f=%e\r\n", f);
float COSPI3=cos(f);
float SQR2=sqr(2);
printf("cos(PI/3)=%e, sqr(2)=%e\r\n", COSPI3, SQR2);
printf("f=%e, COSPI3=%e\r\n", f, COSPI3);
int i = 36;
i = i - 11;
i=i<<4;
printf("i=%I\r\n", i);
float BILLION=1000000000; //9E6E6B2800
printf("BILLION=%e %h%h%h%h%h\r\n", BILLION, BILLION);
unsigned int Test=61027;
printf("Test=%D\r\n", Test);
float a = 66 / 3;
printf("a=%e\r\n", a);
a=a+1;
printf("a=%e\r\n", a);
float mul=256*128;
printf("mul=%e\r\n", mul);
puts("Press a key");
char chr = getchar();
printf("chr=%d\r\n", chr);
int cnt=3;
if (cnt) {
puts("IF block...");
cnt=cnt+1;
printf("cnt=%I\r\n", cnt);
}
puts("Press a key");
chr=getchar();
while (cnt) {
cnt=cnt-1;
printf("cnt=%5I, 0x%H\r\n", cnt, cnt);
}
puts("Press a key");
getchar();
if (0) {
puts("false{{{{{SKIPTHIS");
}
MAN
TEXT /MAKE/USR/SHARE/ctests/ctest

View File

@ -59,4 +59,5 @@ FUNCTION GETXY {
ECHO Not yet implemented
}
MAN
TEXT /MAKE/USR/SHARE/MAKE/MAKEFUNCS
TEXT /MAKE/usr/share/make/makefuncs
TEXT /MAKE/usr/share/adm/help/dispfuncs

46
EXAMPLES/loadvar.txt Normal file
View File

@ -0,0 +1,46 @@
NEW
PREFIX
AUTO 4,1
OS : A2osX::
VERSION : 0.94::
BUILD : 1111::
More than one word:::
Let's : Try with Colons : and see what
happens : to multiple : colon separated things : done here
ok the end :::
MAN
TEXT /MAKE/usr/share/examples/version
NEW
PREFIX
AUTO 4,1
#!/bin/sh
#
# test the whole load variables in set statements
#
set
echo -------------------
for tline in (version)
echo $tline
echo -n "|"
set p1 = `parse $tline | cut -f 1 -s ":"`
set p2 = `parse $tline | cut -f 2 -s ":"`
set p3 = `parse $tline | cut -f 3 -s ":"`
set p4 = `parse $tline | cut -f 4 -s ":"`
echo "> ${p1} <> ${p2} <> ${p3} <> ${p4} <"
next
echo -------------------
set
MAN
TEXT /MAKE/usr/share/examples/loadvar
NEW
PREFIX
AUTO 4,1
#!/bin/sh
#parse script
echo $1
MAN
TEXT /MAKE/usr/share/examples/parse

75
HELP/help.txt Normal file
View File

@ -0,0 +1,75 @@
NEW
PREFIX
AUTO 4,1
#!/bin/sh
#
# This is the Main HELP script
# It displays pages located in usr/share/help
#
function nh {
echo \nHelp is not available for $1
echo "Try \e[7mhelp list\e[0m for a list of help topics\n"
}
set hp = ${BOOT}usr/share/help
if ![ -D ${hp} ]
echo "\nA2osX Help files are not installed"
echo "Please update your A2osX installation\n"
exit
fi
pushd $hp
switch $#
case 0
echo "\nNo Help Argument specified"
echo "try \e[7mhelp help\e[0m for more information on the help command\n"
exit
break
case 1
if [ $1 = "list" ]
ls -R
exit
fi
if [ -f $1 ]
set hf = $1
else
call nh $1
exit
fi
break
case 2
if [ -f "$1.help/$2" ]
set hf = "$1.help/$2"
else
if [ -f $1 ]
set hf = $1
fi
fi
if [ -z $hf ]
call nh "$1 $2"
exit
fi
break
case 3
if [ -f "$1.help/$2.help/$3" ]
set hf = "$1.help/$2.help/$3"
else
call nh "$1 $2 $3"
exit
fi
break
default
echo \nToo Many Arguments\n
end
if [ -n $hf ]
for l in ($hf)
switch $l
case PAGE
pause;break
Case BL
echo;break
default
echo $l
end
next
fi
MAN
TEXT /MAKE/usr/share/adm/help

167
HELP/helphelp.txt Normal file
View File

@ -0,0 +1,167 @@
NEW
PREFIX
AUTO 4,1
A2osX Help Help
BL
The help command displays system, application and program
help files for A2osX. Options include:
BL
help help - displays this help page
help adm - general help on the A2osX Domain Manager
help adm enable - help on the adm enable command
help ls - help on the ls command
help sh - general shell (bin/sh) help
help sh for - help on the shell for command
help list - displays a directory listing of help topics
BL
MAN
TEXT /MAKE/usr/share/help/help
NEW
PREFIX
AUTO 4,1
A2osX Domain Manager Help
BL
ADM or the A2osX Domain Manager is a series of scripts you can use to
perform a variety of administrative functions on your A2osX system.
For help on any of the adm commands use the syntax help adm command
For example you can do
BL
help adm update
help adm enable
help adm app install
BL
MAN
TEXT /MAKE/usr/share/help/adm
NEW
PREFIX
AUTO 4,1
A2osX ADM Update Help
BL
The adm update command allows you to update your current A2osX installation
to the latest build. This command requires a properly installed, configured
and running network infastructure. Update will test that the update.a2osx.net
server can be reached. Update will then compare the currently running version
with the latest version available on the update server.
BL
The update process will install new system files, bins and even an updated
version of ProDOS FX. It will not change files in user home directories
or configuration files stored in ./etc (other then updated the version file
itself).
BL
MAN
TEXT /MAKE/usr/share/help/adm.help/update
NEW
PREFIX
AUTO 4,1
A2osX Edit Help
BL
The edit command allows the user to interactively read and edit standard text
files in A2osX. If you do not specify a file name on the command line, you
will be prompted to enter one when you save your work (control-S). Consult
the help screen below for a list of the special keys that can be used while
editing a file.
BL
A note for the touch typists!: While edit is not a word processor, it still is
one of the most complex programs included in A2osX. It does a lot! A side
affect of this, and due to the lack of a keyboard buffer in the Apple //e, if
you try to speed type while using EDIT some keystrokes may be dropped. This
is most noticeable when using the AppleWin emulator set to 1.0 speed.
Changing the emulator speed to at least 2.0 will significantly reduce or
eliminate the dropped keys.
BL
MAN
TEXT /MAKE/usr/share/help/edit
NEW
PREFIX
AUTO 4,1
A2osX Shell (bin/sh) Special Keys
BL
While entering commands at the A2osX shell prompt, you can use the
following special keys to edit the command line:
BL
Key Usage
----------- --------------------------------------------------------------
DELETE Deletes character to left of cursor, moves rest of line left
Control-C Erases entire command line
Control-D Exits Shell and if user Shell logs you out of your session
Control-Z Deletes character under the cursor
Up Arrow Displays previous command(s) from history.
Down Arrow Displays next command(s) from history.
Left Arrow Moves cursor to the left to edit current command
Right Arrow Moves cursor to the right to edit current command
PAGE
In addition to the editing keys above, you can use the following special
keys while running scripts or executing commands:
BL
Key Usage
----------- --------------------------------------------------------------
Control-C Interrupts running command or script
Open Apple-0 Switches you to the console display
Open Apple-1 Switches you to Virtual Terminals 1 through 8 if so configured
to OA-8
Open Apple-9 Switches you to the GUI display if configured and started
BL
MAN
TEXT /MAKE/usr/share/help/sh.help/keys
NEW
PREFIX
AUTO 4,1
A2osX Shell CD Command Help
BL
cd <value>
BL
The cd command is used to change the current working directory. You must
supply the cd command a valid relative or absolute path. Examples of
relative paths include subdir1 (a sub-directory in the current directory),
../subdir2 (a sub-directory in the parent of the current directory), and
subdir1/subdir3 ( a sub-directory in the sub-directory subdir1 of the current
directory). An absolute path always begins with a / and includes the volume
name of the disk drive to which change the current working directory such as
/MYVOL1/var/logs (the sub-directory logs in the directory var on the disk
with a volume label of MYVOL1).
PAGE
You can use the pwd command to display the current working directory if your
prompt ($) does not automatically display it on the command line (the default,
set in your PROFILE). The current working directory is used by the shell to
look for scripts not located in one of the directories specified by $PATH or
as the directory for reading and writing files when no path is provided by a
command. For example, if you execute the ls command without arguments, ls
assumes to list the files in the current working directory. Similarly, if
you specify a file without a path, for example the command echo Hello >
outfile, shell will place the file outfile in the current working directory.
See the related popd and pushd commands.
BL
MAN
TEXT /MAKE/usr/share/help/sh.help/cd
NEW
PREFIX
AUTO 4,1
A2osX ADM Update Help
MAN
TEXT /MAKE/usr/share/help/x
NEW
PREFIX
AUTO 4,1
A2osX ADM Update Help
MAN
TEXT /MAKE/usr/share/help/x
NEW
PREFIX
AUTO 4,1
A2osX ADM Update Help
MAN
TEXT /MAKE/usr/share/help/x

View File

@ -4,6 +4,7 @@ AUTO 4,1
A2osX.logo
A2OSX.SYSTEM
bin/acc
bin/acos
bin/arp
bin/asm
bin/asm.6502
@ -120,6 +121,8 @@ lib/libblkdev
lib/libcifs
lib/libpak
lib/libtcpip
root/atest
root/GF
root/helloworld.f
root/mandelbrot.f
root/nets

View File

@ -23,26 +23,20 @@ SWITCH $P
END
READ -P "WHICH BUILD NO: " B
IF [ -Z $B ]
ECHO "You did not enter any response."
ECHO
ECHO "Exiting"
ECHO "\nYou did not enter any response.\nExiting\n"
EXIT
FI
SET SRC = "/MAKE/BUILDS/BUILD${B}"
IF [ -D ${SRC} ]
ECHO "\n\nFound Valid BUILD\n"
ELSE
ECHO "\n\nValid BUILD not found."
ECHO
ECHO "Exiting"
ECHO "\n\nValid BUILD not found.\nExiting\n"
EXIT
FI
ECHO "Is this a (R)elease, (C)andidate or (S)table Build"
READ -P "ENTER R C or S: " RCS
IF [ -Z $RCS ]
ECHO "You did not enter any response."
ECHO
ECHO "Exiting"
ECHO "You did not enter any response.\nExiting\n"
EXIT
FI
SWITCH $RCS
@ -106,6 +100,15 @@ md /FULLBOOT/sbin
md /FULLBOOT/sys
md /FULLBOOT/sys/km
md /FULLBOOT/tmp
md /FULLBOOT/usr
md /FULLBOOT/usr/share
md /FULLBOOT/usr/share/adm
md /FULLBOOT/usr/share/extras
md /FULLBOOT/usr/share/help
md /FULLBOOT/usr/share/help/adm.help
md /FULLBOOT/usr/share/help/adm.help/enable.help
md /FULLBOOT/usr/share/help/csh.help
md /FULLBOOT/usr/share/help/sh.help
md /FULLBOOT/var
md /FULLBOOT/var/log
ECHO "Copying Files..."
@ -123,6 +126,10 @@ IF [ $PDOS -eq 1 ]
ECHO Renaming VOL
REN /FULLBOOT FULLBOOT
FI
cp -q helloworld.s /FULLBOOT/root/helloworld.s
cp -q /MAKE/assets/PRODOS242/BASIC.SYSTEM /FULLBOOT/bin/Basic
cp -q /MAKE/SCASM3.SYSTEM /FULLBOOT/bin/SC3
cp -q /MAKE/assets/PRODOS242/COPYIIPLUS.8.4 /FULLBOOT/bin/CP2Plus
ECHO "FULLBOOT Disk Created!"
MAN
TEXT /MAKE/USR/SHARE/MAKE/MAKEFULL

View File

@ -3,12 +3,12 @@ NEW
AUTO 4,1
#!/bin/sh
#
# This script makes a proper fullboot 32mb disk using the files
# This script makes a proper FULLBOOT 32mb disk using the files
# found in a particular BUILD stored in /make/builds
#
. makefuncs
CALL CS
CALL TBOX " fullboot 32mb Media Creator"
CALL TBOX " FULLBOOT 32mb Media Creator"
CALL PRINTXY 8 0 "You must have the correct image mounted on S7D2"
ECHO "\n"
READ -P "Do you want to proceed (Y/N)? " P
@ -66,42 +66,51 @@ SWITCH $RCS
EXIT
END
ECHO "Formatting Destination..."
format -B 65535 s7d2 fullboot
format -B 65535 s7d2 FULLBOOT
ECHO "Making Directory Structure..."
md /fullboot/bin
md /fullboot/drv
md /fullboot/etc
md /fullboot/inc
md /fullboot/lib
md /fullboot/root
md /fullboot/sbin
md /fullboot/sys
md /fullboot/sys/km
md /fullboot/tmp
md /fullboot/usr
md /fullboot/usr/share
md /fullboot/usr/share/extras
md /fullboot/var
md /fullboot/var/log
md /fullboot/var/www
md /FULLBOOT/bin
md /FULLBOOT/drv
md /FULLBOOT/etc
md /FULLBOOT/inc
md /FULLBOOT/lib
md /FULLBOOT/root
md /FULLBOOT/sbin
md /FULLBOOT/sys
md /FULLBOOT/sys/km
md /FULLBOOT/tmp
md /FULLBOOT/usr
md /FULLBOOT/usr/share
md /FULLBOOT/usr/share/adm
md /FULLBOOT/usr/share/extras
md /FULLBOOT/usr/share/help
md /FULLBOOT/usr/share/help/adm.help
md /FULLBOOT/usr/share/help/adm.help/enable.help
md /FULLBOOT/usr/share/help/csh.help
md /FULLBOOT/usr/share/help/sh.help
md /FULLBOOT/var
md /FULLBOOT/var/log
md /FULLBOOT/var/www
ECHO "Copying Files..."
FOR FILE IN (fullfiles)
cp -Q ${SRC}/${FILE} /fullboot/${FILE}
cp -Q ${SRC}/${FILE} /FULLBOOT/${FILE}
NEXT
cp -Q -Y -R ${SRC}/srv/www/* /fullboot/var/www
cp -Q -Y ${SRC}/PRODOS.FX /fullboot/ProDOS
cp -Q -Y ${SRC}/PRODOS.FX /fullboot/usr/share/extras
cp -Q -Y ${SRC}/PRODOS.FX.PAKED /fullboot/usr/share/extras
cp -Q -Y ${SRC}/PRODOS.203TC /fullboot/usr/share/extras
cp -Q -Y ${SRC}/SCASM3.SYSTEM /fullboot/usr/share/extras
cp -Q -Y ${SRC}/NS.CLOCK.SYSTEM /fullboot/usr/share/extras
cp -Q -Y initboot /fullboot/etc/init
ECHO "Welcome to A2osX!" > /fullboot/etc/issue
ECHO >> /fullboot/etc/issue
ECHO $IM >> /fullboot/etc/issue
cp -Q tcpip.conf /fullboot/etc/tcpip.conf
cp -Q profile /fullboot/root/profile
cp -q helloworld.s /fullboot/root/helloworld.s
ECHO "fullboot 32mb Disk Created!"
cp -Q -Y -R ${SRC}/srv/www/* /FULLBOOT/var/www
cp -Q -Y ${SRC}/PRODOS.FX /FULLBOOT/ProDOS
cp -Q -Y ${SRC}/PRODOS.FX /FULLBOOT/usr/share/extras
cp -Q -Y ${SRC}/PRODOS.FX.PAKED /FULLBOOT/usr/share/extras
cp -Q -Y ${SRC}/PRODOS.203TC /FULLBOOT/usr/share/extras
cp -Q -Y ${SRC}/NS.CLOCK.SYSTEM /FULLBOOT/usr/share/extras
cp -Q -Y -R /MAKE/usr/share/help/* /FULLBOOT/usr/share/help
cp -Q -Y initboot /FULLBOOT/etc/init
ECHO "Welcome to A2osX!" > /FULLBOOT/etc/issue
ECHO >> /FULLBOOT/etc/issue
ECHO $IM >> /FULLBOOT/etc/issue
cp -Q tcpip.conf /FULLBOOT/etc/tcpip.conf
cp -Q profile /FULLBOOT/root/profile
cp -q helloworld.s /FULLBOOT/root/helloworld.s
cp -q /MAKE/assets/PRODOS242/BASIC.SYSTEM /FULLBOOT/bin/Basic
cp -q /MAKE/SCASM3.SYSTEM /FULLBOOT/bin/SC3
cp -q /MAKE/assets/PRODOS242/COPYIIPLUS.8.4 /FULLBOOT/bin/CP2Plus
ECHO "FULLBOOT 32mb Disk Created!"
MAN
TEXT /MAKE/USR/SHARE/MAKE/MAKEFULL32

View File

@ -80,15 +80,16 @@ md /a2osxinstall/sbin
md /a2osxinstall/sys
ECHO "Copying Files..."
FOR FILE IN (instbfiles)
cp -Y ${SRC}/${FILE} /miniboot/${FILE}
cp -Y ${SRC}/${FILE} /a2osxinstall/${FILE}
NEXT
cp -Q -Y ${SRC}/PRODOS.FX.PAKED /miniboot/ProDOS
cp -Q -Y initinstall /miniboot/etc/init
ECHO "Welcome to A2osX!" > /miniboot/etc/issue
ECHO >> /miniboot/etc/issue
ECHO $IM >> /miniboot/etc/issue
cp -Q tcpip.conf /miniboot/etc/tcpip.conf
cp -Q profile /miniboot/root/profile
ECHO "miniboot Disk Created!"
cp -Q -Y ${SRC}/PRODOS.FX.PAKED /a2osxinstall/ProDOS
cp -Q -Y initinstall /a2osxinstall/etc/init
cp -Y installscript /a2osxinstall
ECHO "Welcome to A2osX!" > /a2osxinstall/etc/issue
ECHO >> /a2osxinstall/etc/issue
ECHO $IM >> /a2osxinstall/etc/issue
cp -Q tcpip.conf /a2osxinstall/etc/tcpip.conf
cp -Q profile /a2osxinstall/root/profile
ECHO "a2osxinstall Disk Created!"
MAN
TEXT /MAKE/USR/SHARE/MAKE/makeinstall

View File

@ -40,7 +40,9 @@ FI
SET IM = "A2osX NetInst Build No. ${B}"
ECHO "\n\nFormatting Destination..."
#should probably do a check here that right media is in drives
format -1 s6d2 A2osXNetInst
format -1 s6d1 A2osXNetInst
cp -Q -Y ${SRC}/PRODOS.FX.PAKED /A2osXNetInst/ProDOS
cp -Q -Y ${SRC}/A2OSX.SYSTEM /A2osXNetInst/A2osX.SYSTEM
ECHO "Making Directory Structure..."
md /A2osXNetInst/bin
md /A2osXNetInst/drv
@ -48,11 +50,11 @@ md /A2osXNetInst/etc
md /A2osXNetInst/lib
md /A2osXNetInst/sbin
md /A2osXNetInst/sys
cp -Q -Y ${SRC}/sys/kernel.PAKED /A2osXNetInst/sys/kernel
ECHO "Copying Files..."
FOR FILE IN (netinstfiles)
cp -Y ${SRC}/${FILE} /A2osXNetInst/${FILE}
cp -Q -Y ${SRC}/${FILE} /A2osXNetInst/${FILE}
NEXT
cp -Q -Y ${SRC}/PRODOS.FX.PAKED /A2osXNetInst/ProDOS
cp -Q -Y initnetinst /A2osXNetInst/etc/init
cp -Y NetInstall /A2osXNetInst
cp -Q tcpip.conf /A2osXNetInst/etc/tcpip.conf

View File

@ -27,6 +27,15 @@ SWITCH $P
END
ECHO
ECHO "Welcome to A2osX!"
Ask if installing on HD by itself or sharing? Then what to do with ProDOS?
PAUSE
MAN
TEXT /MAKE/USR/SHARE/MAKE/NetInstall

View File

@ -37,6 +37,5 @@ lib/libtcpip
sbin/initd
sbin/insdrv
sbin/networkd
sys/kernel
MAN
TEXT /MAKE/USR/SHARE/MAKE/NETINSTFILES