Linuxnoob Posted October 4, 2008 Share Posted October 4, 2008 Hi, I am pretty new to linux and dn't really have clue of how to do this problem that was given to me. The program that I am using is cygwin, an emularor to replace the actual Linux O/S. Ok here we go, I am supposed to create a script that will produce a text file that has a list of the files in the present working directory. I should be able to do the auto execution from the command prompt. *as hint, use redirection operators* I guess its ">" ------------- What i do know is that using vi text editor in cygwin you start off with #!bin/bash that's all could any of you help me out? I would really appreciate it. Quote Link to comment https://forums.phpfreaks.com/topic/126964-new-to-linux-environment-help/ Share on other sites More sharing options...
trq Posted October 4, 2008 Share Posted October 4, 2008 #!/bin/bash ls -l pwd > filelist Quote Link to comment https://forums.phpfreaks.com/topic/126964-new-to-linux-environment-help/#findComment-656763 Share on other sites More sharing options...
CroNiX Posted October 7, 2008 Share Posted October 7, 2008 thorp gets an "A" for doing your homework for you LOL. Be sure to credit PHPFreaks when you turn that in...wouldn't want to be plagiarizing now would we? Quote Link to comment https://forums.phpfreaks.com/topic/126964-new-to-linux-environment-help/#findComment-659477 Share on other sites More sharing options...
trq Posted October 8, 2008 Share Posted October 8, 2008 Its a shame it won't work without some tweaking. Quote Link to comment https://forums.phpfreaks.com/topic/126964-new-to-linux-environment-help/#findComment-659526 Share on other sites More sharing options...
DarkWater Posted October 8, 2008 Share Posted October 8, 2008 Its a shame it won't work without some tweaking. Do you mean: ls -l $(pwd) > filelist ? You could technically take off the pwd part... Quote Link to comment https://forums.phpfreaks.com/topic/126964-new-to-linux-environment-help/#findComment-659553 Share on other sites More sharing options...
trq Posted October 8, 2008 Share Posted October 8, 2008 Its a shame it won't work without some tweaking. Do you mean: ls -l $(pwd) > filelist ? You could technically take off the pwd part... Indeed, but I figured Linuxnoob would need something to do. Quote Link to comment https://forums.phpfreaks.com/topic/126964-new-to-linux-environment-help/#findComment-659561 Share on other sites More sharing options...
Ghulam Yaseen Posted October 10, 2008 Share Posted October 10, 2008 hello , thisis how the script should look like ------------- #!bin/bash ls > yaseen ------------- Hi, I am pretty new to linux and dn't really have clue of how to do this problem that was given to me. The program that I am using is cygwin, an emularor to replace the actual Linux O/S. Ok here we go, I am supposed to create a script that will produce a text file that has a list of the files in the present working directory. I should be able to do the auto execution from the command prompt. *as hint, use redirection operators* I guess its ">" ------------- What i do know is that using vi text editor in cygwin you start off with #!bin/bash that's all could any of you help me out? I would really appreciate it. Quote Link to comment https://forums.phpfreaks.com/topic/126964-new-to-linux-environment-help/#findComment-661837 Share on other sites More sharing options...
corbin Posted October 12, 2008 Share Posted October 12, 2008 Uh, hasn't that already been said? Quote Link to comment https://forums.phpfreaks.com/topic/126964-new-to-linux-environment-help/#findComment-663156 Share on other sites More sharing options...
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.