RE: OT-Unix grep
Heh I thought I was the only one who ever found humor in that. -Original Message- From: Jochem van Dieten [mailto:[EMAIL PROTECTED] Sent: Wednesday, May 04, 2005 10:54 AM To: CF-Talk Subject: Re: OT-Unix grep [EMAIL PROTECTED] wrote: > Okay kind of an odd thing here. I am trying to use grep to search through files for a string. I and hen just wnat the file name that there was a match for, then I am writing the reuslts to CF web page. Now I can eaisly grep the string but I am simpky want the file name not the actual line for the string found. so Right now I am doing the following: > > grep foo *.* You can use grep to grep the grep manpage for the right syntax: man grep | grep ' -' :) Jochem ~| Logware (www.logware.us): a new and convenient web-based time tracking application. Start tracking and documenting hours spent on a project or with a client with Logware today. Try it for free with a 15 day trial account. http://www.houseoffusion.com/banners/view.cfm?bannerid=67 Message: http://www.houseoffusion.com/lists.cfm/link=i:4:205620 Archives: http://www.houseoffusion.com/cf_lists/threads.cfm/4 Subscription: http://www.houseoffusion.com/lists.cfm/link=s:4 Unsubscribe: http://www.houseoffusion.com/cf_lists/unsubscribe.cfm?user=11502.10531.4 Donations & Support: http://www.houseoffusion.com/tiny.cfm/54
Re: OT-Unix grep
> > Okay kind of an odd thing here. I am trying to use grep to search through > files for a string. I and hen just wnat the file name that there was a match > for, then I am writing the reuslts to CF web page. Now I can eaisly grep the > string but I am simpky want the file name not the actual line for the string > found. so Right now I am doing the following: > > > > grep foo *.* > > grep -c foo * | awk -F':' '{print $1}' This is soo wrong. Use Kola's advice. -- ~| Discover CFTicket - The leading ColdFusion Help Desk and Trouble Ticket application http://www.houseoffusion.com/banners/view.cfm?bannerid=48 Message: http://www.houseoffusion.com/lists.cfm/link=i:4:205518 Archives: http://www.houseoffusion.com/cf_lists/threads.cfm/4 Subscription: http://www.houseoffusion.com/lists.cfm/link=s:4 Unsubscribe: http://www.houseoffusion.com/cf_lists/unsubscribe.cfm?user=89.70.4 Donations & Support: http://www.houseoffusion.com/tiny.cfm/54
Re: OT-Unix grep
[EMAIL PROTECTED] wrote: > Okay kind of an odd thing here. I am trying to use grep to search through > files for a string. I and hen just wnat the file name that there was a match > for, then I am writing the reuslts to CF web page. Now I can eaisly grep the > string but I am simpky want the file name not the actual line for the string > found. so Right now I am doing the following: > > grep foo *.* You can use grep to grep the grep manpage for the right syntax: man grep | grep ' -' :) Jochem ~| Logware (www.logware.us): a new and convenient web-based time tracking application. Start tracking and documenting hours spent on a project or with a client with Logware today. Try it for free with a 15 day trial account. http://www.houseoffusion.com/banners/view.cfm?bannerid=67 Message: http://www.houseoffusion.com/lists.cfm/link=i:4:205517 Archives: http://www.houseoffusion.com/cf_lists/threads.cfm/4 Subscription: http://www.houseoffusion.com/lists.cfm/link=s:4 Unsubscribe: http://www.houseoffusion.com/cf_lists/unsubscribe.cfm?user=89.70.4 Donations & Support: http://www.houseoffusion.com/tiny.cfm/54
Re: OT-Unix grep
> Okay kind of an odd thing here. I am trying to use grep to search through files for a string. I and hen just wnat the file name that there was a match for, then I am writing the reuslts to CF web page. Now I can eaisly grep the string but I am simpky want the file name not the actual line for the string found. so Right now I am doing the following: > > grep foo *.* grep -c foo * | awk -F':' '{print $1}' -- ~| Find out how CFTicket can increase your company's customer support efficiency by 100% http://www.houseoffusion.com/banners/view.cfm?bannerid=49 Message: http://www.houseoffusion.com/lists.cfm/link=i:4:205516 Archives: http://www.houseoffusion.com/cf_lists/threads.cfm/4 Subscription: http://www.houseoffusion.com/lists.cfm/link=s:4 Unsubscribe: http://www.houseoffusion.com/cf_lists/unsubscribe.cfm?user=11502.10531.4 Donations & Support: http://www.houseoffusion.com/tiny.cfm/54
RE: OT-Unix grep
Perhaps: grep foo *.* -l May differ depending on your version of *nix try the man pages. HTH Kola > -Original Message- > From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED] > Sent: 04 May 2005 14:33 > To: CF-Talk > Subject: OT-Unix grep > > Okay kind of an odd thing here. I am trying to use grep to search through > files for a string. I and hen just wnat the file name that there was a > match for, then I am writing the reuslts to CF web page. Now I can eaisly > grep the string but I am simpky want the file name not the actual line for > the string found. so Right now I am doing the following: > > grep foo *.* > > > > > > ~| Logware (www.logware.us): a new and convenient web-based time tracking application. Start tracking and documenting hours spent on a project or with a client with Logware today. Try it for free with a 15 day trial account. http://www.houseoffusion.com/banners/view.cfm?bannerid=67 Message: http://www.houseoffusion.com/lists.cfm/link=i:4:205515 Archives: http://www.houseoffusion.com/cf_lists/threads.cfm/4 Subscription: http://www.houseoffusion.com/lists.cfm/link=s:4 Unsubscribe: http://www.houseoffusion.com/cf_lists/unsubscribe.cfm?user=89.70.4 Donations & Support: http://www.houseoffusion.com/tiny.cfm/54
OT-Unix grep
Okay kind of an odd thing here. I am trying to use grep to search through files for a string. I and hen just wnat the file name that there was a match for, then I am writing the reuslts to CF web page. Now I can eaisly grep the string but I am simpky want the file name not the actual line for the string found. so Right now I am doing the following: grep foo *.* ~| Logware (www.logware.us): a new and convenient web-based time tracking application. Start tracking and documenting hours spent on a project or with a client with Logware today. Try it for free with a 15 day trial account. http://www.houseoffusion.com/banners/view.cfm?bannerid=67 Message: http://www.houseoffusion.com/lists.cfm/link=i:4:205511 Archives: http://www.houseoffusion.com/cf_lists/threads.cfm/4 Subscription: http://www.houseoffusion.com/lists.cfm/link=s:4 Unsubscribe: http://www.houseoffusion.com/cf_lists/unsubscribe.cfm?user=11502.10531.4 Donations & Support: http://www.houseoffusion.com/tiny.cfm/54
Re: OT Unix
On Fri, 13 Aug 2004 10:42:29 -0400, S. Isaac Dealey <[EMAIL PROTECTED]> wrote: > Thanks Dave, that's a great explanation, and not more info than I > needed -- I hadn't even noticed that wasn't a regular chmod value when > I googled it. But the explanation makes it all a lot clearer and will > help if I ever have to google it in the future. :) > > > Since we tend to think in terms of permissions that > > a directory does have (i.e., chmod 755 directory_name), > > umask just seems like a funny implementation > > (much like using compare() and NOT compare() in CF!!). > > Yea, should have been contrast() :) -- if they're > different... suppose it would be easy enough to wrapper that... > > function contrast(x,y) { return compare(x,y); } > > Though most of the time that's just more trouble than it's worth. :) Ha. True. I've always been a fan of calling a spade a spade. Why can't it be isEqual(x,y) and isEqualNoCase(x,y)? Yes this could be a UDF, but, as you point out, it's more trouble than it's worth!! Glad the umask explanation helped. Regards, Dave. [Todays Threads] [This Message] [Subscription] [Fast Unsubscribe] [User Settings] [Donations and Support]
Re: OT Unix
Thanks Dave, that's a great explanation, and not more info than I needed -- I hadn't even noticed that wasn't a regular chmod value when I googled it. But the explanation makes it all a lot clearer and will help if I ever have to google it in the future. :) > Since we tend to think in terms of permissions that > a directory does have (i.e., chmod 755 directory_name), > umask just seems like a funny implementation > (much like using compare() and NOT compare() in CF!!). Yea, should have been contrast() :) -- if they're different... suppose it would be easy enough to wrapper that... function contrast(x,y) { return compare(x,y); } Though most of the time that's just more trouble than it's worth. :) s. isaac dealey 954.927.5117 new epoch : isn't it time for a change? add features without fixtures with the onTap open source framework http://www.sys-con.com/story/?storyid=44477&DE=1 [Todays Threads] [This Message] [Subscription] [Fast Unsubscribe] [User Settings] [Donations and Support]
Re: OT Unix
On Fri, 13 Aug 2004 08:49:52 -0400, S. Isaac Dealey <[EMAIL PROTECTED]> wrote: > Thanks Dave... I'm not even sure what a "umask" is. heh :) It'd been a > while since I'd done anything with it, and you know, googling for > chmod doesn't produce very intuitive results. :) > No worries. I've always found umask to be counter-intuitive. Briefly, what it does is sets the default *disabled* bit permissions for a new directory (using mkdir). It is a configurable setting that is usually found in your profile script (if you use the bash shell, it would likely be in your .bash_profile). What I mean by disabled bits is that its value determines what permissions the directory *doesn't* have, as opposed to the permissions the directory *does* have. Since we tend to think in terms of permissions that a directory does have (i.e., chmod 755 directory_name), umask just seems like a funny implementation (much like using compare() and NOT compare() in CF!!). The most common umask I've seen is 022. So to determine what permissions a directory will have by default, you'd subtract the umask value from 777 (which is the bit representation for full read/write/execute permissions): 777 - 022 - 755 So 755 will be the default permissions on creating all directories under your user name, which is full read/write/execute for the owner, and read/execute for the group and others. I know this is way more information than you probably ever wanted, but hopefully this helps you understand better why umask wasn't the answer to the initial post's problem. Regards, Dave. [Todays Threads] [This Message] [Subscription] [Fast Unsubscribe] [User Settings] [Donations and Support]
Re: OT Unix
> On Thu, 12 Aug 2004 21:14:23 -0400, S. Isaac Dealey > <[EMAIL PROTECTED]> wrote: >> 022 ? >> >> http://www.bu.edu/cc/support/aboutunix/commands/umask/ >> > No, you wouldn't use the umask in this case. I think the > previously > made suggestion of 755 is more than sufficient, and 744 > might be even > better. That means that the owner will have full > read/write/execute > permissions while the group and others will have read-only > permissions, which is perfectly fine for the purposes of > allowing > downloads. Thanks Dave... I'm not even sure what a "umask" is. heh :) It'd been a while since I'd done anything with it, and you know, googling for chmod doesn't produce very intuitive results. :) s. isaac dealey 954.927.5117 new epoch : isn't it time for a change? add features without fixtures with the onTap open source framework http://www.sys-con.com/story/?storyid=44477&DE=1 http://www.sys-con.com/story/?storyid=45569&DE=1 http://www.fusiontap.com [Todays Threads] [This Message] [Subscription] [Fast Unsubscribe] [User Settings] [Donations and Support]
Re: OT Unix
Paul Giesenhagen wrote: > If you want to create a directory with cfdirectory that is moving a file from one location into the newly created directory and you wanted it to be available for download via http ... what MODE would you set on the new directory and file? Presuming you want the directory to be directly accessible and not through cfcontent and that your webserver runs under nobody it would be reasonable to make it 755 on directories and 644 on files. Jochem [Todays Threads] [This Message] [Subscription] [Fast Unsubscribe] [User Settings] [Donations and Support]
Re: OT Unix
On Thu, 12 Aug 2004 21:14:23 -0400, S. Isaac Dealey <[EMAIL PROTECTED]> wrote: > 022 ? > > http://www.bu.edu/cc/support/aboutunix/commands/umask/ > No, you wouldn't use the umask in this case. I think the previously made suggestion of 755 is more than sufficient, and 744 might be even better. That means that the owner will have full read/write/execute permissions while the group and others will have read-only permissions, which is perfectly fine for the purposes of allowing downloads. [Todays Threads] [This Message] [Subscription] [Fast Unsubscribe] [User Settings] [Donations and Support]
Re: OT Unix
Perfect .. thanks! Paul Giesenhagen QuillDesign 417-885-1375 http://www.quilldesign.com - Original Message - From: chris johnson To: CF-Talk Sent: Thursday, August 12, 2004 9:03 PM Subject: Re: OT Unix On Thu, 12 Aug 2004 21:51:27 -0400, S. Isaac Dealey <[EMAIL PROTECTED]> wrote: > I thought you only needed read rights to download it and that 777 > would provide all users with all rights (including delete)? ... > Granted that I'm pretty sure there's no way to take advantage of > delete privileges via a web browser, but then I'm not a unix guru > either, so... In part, the permissions that you place on the file will depend on how you wish to distribute the file. If you are going to link to the file directly, then you should allow for read only and not write or execute (744). If you are going to use CFMX to server up the file to your users, then all you really need to provide is enough permissions to allow CF to access the file. As the file should be created using the same user and group that CF is running under, something as little as 700 should do it. -- chris johnston www.fuzzylizard.com "For millions of years, mankind lived just like the animals and something happened which unleashed the power of our imagination, we learned to talk." Pink Floyd [Todays Threads] [This Message] [Subscription] [Fast Unsubscribe] [User Settings] [Donations and Support]
Re: OT Unix
On Thu, 12 Aug 2004 21:51:27 -0400, S. Isaac Dealey <[EMAIL PROTECTED]> wrote: > I thought you only needed read rights to download it and that 777 > would provide all users with all rights (including delete)? ... > Granted that I'm pretty sure there's no way to take advantage of > delete privileges via a web browser, but then I'm not a unix guru > either, so... In part, the permissions that you place on the file will depend on how you wish to distribute the file. If you are going to link to the file directly, then you should allow for read only and not write or execute (744). If you are going to use CFMX to server up the file to your users, then all you really need to provide is enough permissions to allow CF to access the file. As the file should be created using the same user and group that CF is running under, something as little as 700 should do it. -- chris johnston www.fuzzylizard.com "For millions of years, mankind lived just like the animals and something happened which unleashed the power of our imagination, we learned to talk." Pink Floyd [Todays Threads] [This Message] [Subscription] [Fast Unsubscribe] [User Settings] [Donations and Support]
RE: OT Unix
I thought you only needed read rights to download it and that 777 would provide all users with all rights (including delete)? ... Granted that I'm pretty sure there's no way to take advantage of delete privileges via a web browser, but then I'm not a unix guru either, so... > sorry I did not know you were seeking a mode less than > providing the > item for download for all users. In UNIX is should be > accessible by > the same user that ColdFusion application server is > running as right? > Would that provide the file to everyone the same way? > _ > From: Paul Giesenhagen [mailto:[EMAIL PROTECTED] > Sent: Thursday, August 12, 2004 8:21 PM > To: CF-Talk > Subject: Re: OT Unix > Yes, that is alittle strong .. I was thinking it was 755 > .. but wanted to > make sure from some of the U Guru's out there. > Paul Giesenhagen > QuillDesign > 417-885-1375 > http://www.quilldesign.com > - Original Message - > From: S. Isaac Dealey > To: CF-Talk > Sent: Thursday, August 12, 2004 8:15 PM > Subject: RE: OT Unix > that's all permissions to all users right? > > mode=777 > > _ > > From: Paul Giesenhagen [mailto:[EMAIL PROTECTED] > > Sent: Thursday, August 12, 2004 8:07 PM > > To: CF-Talk > > Subject: OT Unix > > If you want to create a directory with cfdirectory > > that is > > moving a file > > from one location into the newly created directory and > > you > > wanted it to be > > available for download via http ... what MODE would > > you > > set on the new > > directory and file? > > Paul Giesenhagen > > QuillDesign > > 417-885-1375 > > http://www.quilldesign.com > > _ > s. isaac dealey 954.927.5117 > new epoch : isn't it time for a change? > add features without fixtures with > the onTap open source framework > http://www.sys-con.com/story/?storyid=44477&DE=1 > http://www.sys-con.com/story/?storyid=45569&DE=1 > http://www.fusiontap.com > _ > [Todays Threads] [This Message] [Subscription] [Fast Unsubscribe] [User Settings] [Donations and Support]
RE: OT Unix
sorry I did not know you were seeking a mode less than providing the item for download for all users. In UNIX is should be accessible by the same user that ColdFusion application server is running as right? Would that provide the file to everyone the same way? _ From: Paul Giesenhagen [mailto:[EMAIL PROTECTED] Sent: Thursday, August 12, 2004 8:21 PM To: CF-Talk Subject: Re: OT Unix Yes, that is alittle strong .. I was thinking it was 755 .. but wanted to make sure from some of the U Guru's out there. Paul Giesenhagen QuillDesign 417-885-1375 http://www.quilldesign.com - Original Message - From: S. Isaac Dealey To: CF-Talk Sent: Thursday, August 12, 2004 8:15 PM Subject: RE: OT Unix that's all permissions to all users right? > mode=777 > _ > From: Paul Giesenhagen [mailto:[EMAIL PROTECTED] > Sent: Thursday, August 12, 2004 8:07 PM > To: CF-Talk > Subject: OT Unix > If you want to create a directory with cfdirectory that is > moving a file > from one location into the newly created directory and you > wanted it to be > available for download via http ... what MODE would you > set on the new > directory and file? > Paul Giesenhagen > QuillDesign > 417-885-1375 > http://www.quilldesign.com > _ s. isaac dealey 954.927.5117 new epoch : isn't it time for a change? add features without fixtures with the onTap open source framework http://www.sys-con.com/story/?storyid=44477&DE=1 http://www.sys-con.com/story/?storyid=45569&DE=1 http://www.fusiontap.com _ [Todays Threads] [This Message] [Subscription] [Fast Unsubscribe] [User Settings] [Donations and Support]
Re: OT Unix
Yes, that is alittle strong .. I was thinking it was 755 .. but wanted to make sure from some of the U Guru's out there. Paul Giesenhagen QuillDesign 417-885-1375 http://www.quilldesign.com - Original Message - From: S. Isaac Dealey To: CF-Talk Sent: Thursday, August 12, 2004 8:15 PM Subject: RE: OT Unix that's all permissions to all users right? > mode=777 > _ > From: Paul Giesenhagen [mailto:[EMAIL PROTECTED] > Sent: Thursday, August 12, 2004 8:07 PM > To: CF-Talk > Subject: OT Unix > If you want to create a directory with cfdirectory that is > moving a file > from one location into the newly created directory and you > wanted it to be > available for download via http ... what MODE would you > set on the new > directory and file? > Paul Giesenhagen > QuillDesign > 417-885-1375 > http://www.quilldesign.com > _ s. isaac dealey 954.927.5117 new epoch : isn't it time for a change? add features without fixtures with the onTap open source framework http://www.sys-con.com/story/?storyid=44477&DE=1 http://www.sys-con.com/story/?storyid=45569&DE=1 http://www.fusiontap.com [Todays Threads] [This Message] [Subscription] [Fast Unsubscribe] [User Settings] [Donations and Support]
RE: OT Unix
that's all permissions to all users right? > mode=777 > _ > From: Paul Giesenhagen [mailto:[EMAIL PROTECTED] > Sent: Thursday, August 12, 2004 8:07 PM > To: CF-Talk > Subject: OT Unix > If you want to create a directory with cfdirectory that is > moving a file > from one location into the newly created directory and you > wanted it to be > available for download via http ... what MODE would you > set on the new > directory and file? > Paul Giesenhagen > QuillDesign > 417-885-1375 > http://www.quilldesign.com > _ s. isaac dealey 954.927.5117 new epoch : isn't it time for a change? add features without fixtures with the onTap open source framework http://www.sys-con.com/story/?storyid=44477&DE=1 http://www.sys-con.com/story/?storyid=45569&DE=1 http://www.fusiontap.com [Todays Threads] [This Message] [Subscription] [Fast Unsubscribe] [User Settings] [Donations and Support]
Re: OT Unix
022 ? http://www.bu.edu/cc/support/aboutunix/commands/umask/ > If you want to create a directory with cfdirectory that is > moving a file from one location into the newly created > directory and you wanted it to be available for download > via http ... what MODE would you set on the new directory > and file? > Paul Giesenhagen > QuillDesign > 417-885-1375 > http://www.quilldesign.com s. isaac dealey 954.927.5117 new epoch : isn't it time for a change? add features without fixtures with the onTap open source framework http://www.sys-con.com/story/?storyid=44477&DE=1 http://www.sys-con.com/story/?storyid=45569&DE=1 http://www.fusiontap.com [Todays Threads] [This Message] [Subscription] [Fast Unsubscribe] [User Settings] [Donations and Support]
RE: OT Unix
mode=777 _ From: Paul Giesenhagen [mailto:[EMAIL PROTECTED] Sent: Thursday, August 12, 2004 8:07 PM To: CF-Talk Subject: OT Unix If you want to create a directory with cfdirectory that is moving a file from one location into the newly created directory and you wanted it to be available for download via http ... what MODE would you set on the new directory and file? Paul Giesenhagen QuillDesign 417-885-1375 http://www.quilldesign.com _ [Todays Threads] [This Message] [Subscription] [Fast Unsubscribe] [User Settings] [Donations and Support]
OT Unix
If you want to create a directory with cfdirectory that is moving a file from one location into the newly created directory and you wanted it to be available for download via http ... what MODE would you set on the new directory and file? Paul Giesenhagen QuillDesign 417-885-1375 http://www.quilldesign.com [Todays Threads] [This Message] [Subscription] [Fast Unsubscribe] [User Settings] [Donations and Support]
OT: Unix/CF hosts
Ok, I hate to bring this up, but I am looking for a Hosting company that offers Unix CF Hosting (preferably on CF5). RedHat mySQL/PostgreSQL ect.. Needs to be cheap it is for demo/testing. iServers offers a package on Solaris starting at $150.00 but hopefully we can find something a bit cheaper ... Thanks Paul Giesenhagen QuillDesign __ This list and all House of Fusion resources hosted by CFHosting.com. The place for dependable ColdFusion Hosting. FAQ: http://www.thenetprofits.co.uk/coldfusion/faq Archives: http://www.mail-archive.com/cf-talk@houseoffusion.com/ Unsubscribe: http://www.houseoffusion.com/index.cfm?sidebar=lists
OT - Unix Last Resort
Being at the end of my wits - I have to ask the list the following OT question. Please send any responses to me off list, any input is greatly appreciated. We have inherited a client UNIX box to co-lo. They have it setup as a web server - however when I boot it and it starts the CDE desktop, there is no mouse. I DO have a cursor, but the mouse will not work. I can navigate with the keyboard though. I know this may sound silly but I cannot figure out the problem to save me. The client has no help to offer and insists it worked fine when it was sent - indeed just built for us to host. I have changed the mouse to no avail. I am sorry to say I am not Unix wise. Researching the web and texts has not been any help. I have tried finding local resources without much luck and my tech associates are tired of hearing me pound them for information. ~~ Structure your ColdFusion code with Fusebox. Get the official book at http://www.fusionauthority.com/bkinfo.cfm FAQ: http://www.thenetprofits.co.uk/coldfusion/faq Archives: http://www.mail-archive.com/cf-talk@houseoffusion.com/ Unsubscribe: http://www.houseoffusion.com/index.cfm?sidebar=lists
OT UNIX QUESTION W/CFEXECUTE
I've running Sybase SQL (same as sql) on Linux We have 4.5 and i'm using CFEXECUTe to run a unix script to create a USER What i need to do is find a way to pass the %1(username) %2(password) to the script so i can say ok create user TESTUSER with password blah that way its automates it Any ideas -- Archives: http://www.mail-archive.com/cf-talk@houseoffusion.com/ To Unsubscribe visit http://www.houseoffusion.com/index.cfm?sidebar=lists&body=lists/cf_talk or send a message to [EMAIL PROTECTED] with 'unsubscribe' in the body.