diff --git a/Makefile.in b/Makefile.in index 62dbc4f..1b7810a 100644 --- a/Makefile.in +++ b/Makefile.in @@ -75,6 +75,7 @@ install: install_steam force $(INSTALL) -m755 tools/export_users $(DESTDIR)/$(STEAMDIR)/tools $(INSTALL) -m755 tools/debug.pike $(DESTDIR)/$(STEAMDIR)/tools $(INSTALL) -m644 tools/applauncher.pike $(DESTDIR)/$(STEAMDIR)/tools + $(INSTALL) -m755 steam /usr/bin $(INSTALL) -m755 sources/steam/steam $(DESTDIR)/$(STEAMDIR)/bin/$(STEAMBRAND) $(INSTALL) -m755 start $(DESTDIR)/$(STEAMDIR) diff --git a/steam b/steam new file mode 100644 index 0000000..be5d2c4 --- /dev/null +++ b/steam @@ -0,0 +1,31 @@ +#!/usr/local/pike/7.8.866/bin/pike + +void resolveParam(int argc,array(string) argv) +{ + if(argv[1]=="shell") + { + array command =({"/usr/local/lib/steam/tools/steam-shell.pike"}); + object shell = Process.create_process(command,(["stdin":Stdio.stdin,"stdout":Stdio.stdout,"stderr":Stdio.stderr])); + shell->wait(); + } + else if (argv[1]=="debug") + { + array command = ({"/usr/local/lib/steam/tools/debug.pike"}); + object shell = Process.create_process(command,(["stdin":Stdio.stdin,"stdout":Stdio.stdout,"stderr":Stdio.stderr])); + shell->wait(); + } + else if(argv[1]=="edit") + { + array command = ({"/usr/local/lib/steam/tools/edit.pike"})+argv[2..]; + object shell = Process.create_process(command,(["stdin":Stdio.stdin,"stdout":Stdio.stdout,"stderr":Stdio.stderr])); + shell->wait(); + } +} + +int main(int argc,array(string) argv) +{ + if(argc==1)write("No arguments provided\n");//print help + else resolveParam(argc,argv); + return 0; +} +