Search Results

Search found 14591 results on 584 pages for 'scripting language'.

Page 113/584 | < Previous Page | 109 110 111 112 113 114 115 116 117 118 119 120  | Next Page >

  • what does < < mean in the shell

    - by stib
    when looping recursively through folders with files containing spaces the shell script I use is of this form, copied from the internet: while IFS= read -r -d $'\0' file; do dosomethingwith "$file" # do something with each file done < <(find /bar -name *foo* -print0) I think I understand he IFS bit, but I don't understand what the < < characters mean. Obviously there's some sort of piping going on here.. It's very hard to google "< <", you see. TIA -stib

    Read the article

  • How to get the list of files in a directory in a shell script?

    - by jrharshath
    Hi, I'm trying to get the contents of a directory using shell script. My script is: for entry in `ls $search_dir`; do echo $entry done where $search_dir is a relative path. However, $search_dir contains many files with whitespaces in their names. In that case, this script does not run as expected. I know I could use for entry in *, but that would only work for my current directory. I know I can change to that directory, use for entry in * then change back, but my particular situation prevents me from doing that. I have two relative paths $search_dir and $work_dir, and I have to work on both simultaneously, reading them creating/deleting files in them etc. So what do I do now? PS: I use bash.

    Read the article

  • Batch Create Java Class Stubs

    - by user344639
    Given a list of potential class names: 1. Alaska . . . 50. Wyoming Is there a tool that will create empty java class files for each with supplied parameters? I'm thinking of something like the "New...Class" dialog in Eclipse, only on steriods. :-) Thanks in advance, Kyle

    Read the article

  • How to bundle shell script and C code?

    - by eSKay
    I have a C shell script that calls two C programs - one after the another with some file handling before, in-between and afterwards. Now, as such I have three different files - one C shell script and 2 .c files. I need to give this script to other users. The problem is that I have to distribute three files - which the users must keep in the same folder and then execute the script. Is there some better way to do this? [I know I can make one C code file out of those two... but I will still be left with a shell script and a C code. Actually, the two C codes do entirely different things... so I want them to be separate]

    Read the article

  • Getting the text from a drop-down box

    - by Teifion
    This gets the value of whatever is selected in my dropdown menu. document.getElementById('newSkill').value I cannot however find out what property to go after for the text that's currently displayed by the drop down menu. I tried "text" then looked at W3Schools but that didn't have the answer, does anybody here know? For those not sure, here's the HTML for a drop down box. <select name="newSkill" id="newSkill" <option value="1"A skill</option <option value="2"Another skill</option <option value="3"Yet another skill</option </select Thanks

    Read the article

  • How to warn for the use of unset variables in a korn shell script

    - by Lepu
    Is there any way to throw errors or warnings in a korn shell script to prevent the use of unset variables ? Let's assume I have a temporary folder that I want to remove. TEMP_FILES_DIR='/app/myapp/tmp' rm -Rf $TEMP_FILE_DIR #notice the misspelling How to prevent this kind of mistakes before they actually happen? I know the script should check for file existence and empty string before attempting to remove, this is just a silly example to illustrate a mistake that could have been avoided with some warnings. I don't know if this feature exists in ksh. If it does exist, how do you turn it on?

    Read the article

  • grep a rar in cygwin

    - by Tomer
    Hi, I want to do grep texts files inside a rar without extracting the rar file to disk, I tried a couple of combinations with pipes however it didnt work i tried for example unrar e myrar.rar | grep mysearchedline however it actually opened it to disk, I don't want to open it to disk, I don't have enough space for it to be opened (its real big with real big logs). Thanks.

    Read the article

  • Creating a menu to switch languages on site

    - by user342391
    I have a dropdown menu on my site that I want to use to switch between the different languages: <select onChange="if(this.selectedIndex!=0) self.location=this.options[this.selectedIndex].value" name="userLanguage" id="userLanguage"> <option value="http://demo.com/?lang=en"> English (International)</option> <option value="http://demo.com/?lang=es"> Español (European)</option> </select> How can I get the above menu to display which language is currently showing. Is there someway of showing an active state. Site is using php. Thanks in advance.

    Read the article

  • User controlled html title tags

    - by zaf
    What are the best practices for allowing a user to maintain the html title tags of all the major pages of his/her site? One way could be to allow the mapping of URLs to some text. For example, we have an app with the following (most complex) url format: http://lang.example.com/searchpage.zaf?a=foo&b=bar&c=RANDOM There are several parts to this: Language sub domain Search page Static parameter 'a' (user may want this in the title) Dynamic and relevant parameter 'b' (user may want this in the title) Dynamic parameter 'c' which can be ignored Never done this before, so I'm asking how you would tackle this!

    Read the article

  • Custom Output => List of Errors interpretation in VS2008 IDE.

    - by Hamish Grubijan
    Hello, I have a "database solution" project in VS2008 - it generates SQL for more than one DB vendor from some sort of templates. In order to save time, I also have a tool in VS2008 configured (a Python script), which can compile an individual stored procedure. Now, with the Python script I have the freedom of processing the output and have it take on whatever form I want. I am toying with an idea of having these errors and warnings somehow recognized and populating the click-able Error / Warning list. This is what a typical Oracle error looks like: LINE/COL ERROR -------- ----------------------------------------------------------------- 324/5 PL/SQL: Statement ignored 324/82 PLS-00363: expression 'VSOURCE_SYSTEM_ID' cannot be used as an assignment target Warning: Procedure created with compilation errors. PROCEDURE: ADD_PROPOSED error on creation Errors for PROCEDURE ADD_PROPOSED: LINE/COL ERROR This might be a long shot, but it is worthwhile for me. I do this stuff a lot. Thank you!

    Read the article

  • looking for a javascript engine

    - by c0f33.alex
    i'm looking for a js engine to that I can (easily) expose C/C++ functions, classes etc. The API should allow changing exposed values from within C++ (by storing some kind of pointer or reference to an object inside js or so...). I've considered using google's v8 but I'm new to it and don't know whether it will satisfy my requirements. Can someone tell me whether I should stick to v8 or try something else?

    Read the article

  • Need ideas for reprocessing images using attachment_fu

    - by cswebgrl
    Hi, I discovered a bug in my Rails app due to Rails app and gems upgrades and undocumented code from the previous developers. I have a lot of images that have been processed, but not sized correctly using attachment_fu. All of the images that were uploaded since the upgrade need to be resized correctly. Does anyone have any ideas to reprocess all of the images within the folders and resize them to the correct sizes? I'd hate to have to do these all manually. THANKS!! Cindy

    Read the article

  • Any chances to imitate times() Ruby method in C#?

    - by Alexander Prokofyev
    Every time I need to do something N times inside an algorithm using C# I write this code for (int i = 0; i < N; i++) { ... } Studying Ruby I have learned about method times() which can be used with the same semantics like this N.times do ... end Code fragment in C# looks more complex and we should declare useless variable i. I tried to write extension method which returns IEnumerable, but I am not satisfied with the result because again I have to declare a cycle variable i. public static class IntExtender { public static IEnumerable Times(this int times) { for (int i = 0; i < times; i++) yield return true; } } ... foreach (var i in 5.Times()) { ... } Is it possible using some new C# 3.0 language features to make N times cycle more elegant?

    Read the article

  • Testing the load factor in my lab [closed]

    - by Ami Winter
    I am a system admin in a lab, I have ~90 computers in the lab and I want to check the load factor on them.. meaning, to check how many people are working on the computers hourly.. To see if I need to buy more computers or not. I am looking for a way to build a script to check if a computer is logged on or not.. (0 for log off - 1 for log on) After I will have this data, I know how to build a script to build me the graphs. All the computers are linked via a domain and most of them have windows XP (few windows 7) I'll be happy to get some help. Amihay

    Read the article

  • To change svn revision text

    - by uzay95
    I wrote a script which can auto commit in every 10 minutes. But it's commit message always same ("Code saved"). But i want to change some of them which are milestone. This is my auto commit script: cd c:\inetpub\wwwroot\siteCodes svn commit -m "Code Saved" How can i write a script which can give me a chance to write revision number and new commit message.

    Read the article

  • bash "map" equivalent: run command on each file

    - by Claudiu
    I often have a command that processes one file, and I want to run it on every file in a directory. Is there any built-in way to do this? For example, say I have a program data which outputs an important number about a file: ./data foo 137 ./data bar 42 I want to run it on every file in the directory in some manner like this: map data `ls *` ls * | map data to yield output like this: foo: 137 bar: 42

    Read the article

  • Regarding PID Shell Script

    - by arav
    I am calling another shell script testarg.sh within my main script. the logfiles of testarg.sh are stored in $CUSTLOGS in the below format testarg.DDMONYY.PID.log example: testarg.09Jun10.21165.log In the main script after the testarg process gets completed i need to grep the log file for the text "ERROR" and "COMPLETED SUCCESSFULLY". How do i get the PID of the process and combine with DDMONYY for grepping. Also i need to check whether file exists before grepping $CUSTBIN/testarg.sh $CUSTBIN/testarg.sh rc=$? if [ $rc -ne 0 ]; then return $CODE_WARN fi

    Read the article

  • How do I escape a string for a shell command in nodejs (V8 Javascript engine)?

    - by Maciek
    In nodejs, the only way to execute external commands is via sys.exec(cmd). I'd like to call an external command and give it data via stdin. In nodejs there does yet not appear to be a way to open a command and then push data to it (only to exec and receive its standard+error outputs), so it appears the only way I've got to do this right now is via a single string command such as: var dangerStr = "bad stuff here"; sys.exec("echo '" + dangerStr + "' | somecommand"); Most answers to questions like this have focused on either regex which doesn't work for me in nodejs (which uses Google's V8 Javascript engine) or native features from other languages like Python. I'd like to escape dangerStr so that it's safe to compose an exec string like the one above. If it helps, dangerStr will contain JSON data.

    Read the article

< Previous Page | 109 110 111 112 113 114 115 116 117 118 119 120  | Next Page >