OK, So bassically, I'm making a program and I have a lot of PC's I want to install it on,
but the thing is, I don't want to type is all out over and over, so I thought why not an "install" disk?
where I'd put a drive next to the console, put the disk in, and it would overwrite the startup with new code for my program, how would I accomplish the editting of startup within a program? Many thanks!
0
Automatic program editing?
Started by bloodless2010, Jul 15 2012 09:23 PM
5 replies to this topic
#1
Posted 15 July 2012 - 09:23 PM
#2
Posted 15 July 2012 - 09:30 PM
Take a look at the fs api, specifically fs.copy.
Then just put the program in the disk and make the startup copy it to the computer.
Note: when using fs.copy, if the destination file already exists it will throw an error. You have to check if the file exists, and delete it before copying.
Then just put the program in the disk and make the startup copy it to the computer.
Note: when using fs.copy, if the destination file already exists it will throw an error. You have to check if the file exists, and delete it before copying.
#3
Posted 16 July 2012 - 02:04 PM
I think the even easier solution is to just use shell.run("copy", "disk/file", "startup")
#4
Posted 16 July 2012 - 02:44 PM
Yes, but he said overwrite, and copy throws an error if the file exists.
#5
Posted 16 July 2012 - 03:48 PM
for the install try using this code as the startup code on the disk (its quite easy tbh)
Spoiler
the only problem with this is that i have found fs.delete sometimes says action not allowed or something
#6
Posted 16 July 2012 - 11:02 PM
awsumben13, on 16 July 2012 - 03:48 PM, said:
for the install try using this code as the startup code on the disk (its quite easy tbh)
Spoiler
the only problem with this is that i have found fs.delete sometimes says action not allowed or something
Spoiler
Does the same, just shortened it up
1 user(s) are reading this topic
0 members, 1 guests, 0 anonymous users