Search Results

Search found 2348 results on 94 pages for 'cat pants'.

Page 5/94 | < Previous Page | 1 2 3 4 5 6 7 8 9 10 11 12  | Next Page >

  • zsh: Do NOT expand wildcard on tab completion

    - by BMorgenthaler
    I'm wondering how I can configure ZSH to NOT expand the wildcard in a filename. So for example I have a directory of a couple hundred files named like so: a.foo-bar a.foo b.foo-bar b.foo c.foo-bar c.foo I would like to be able to perform a tab completion matching AFTER a wildcard, so cat *.foo-< tab = cat *.foo-bar instead what I get is cat *.foo-< tab = cat a.foo-bar file a.foo-bar b.foo-bar c.foo-bar

    Read the article

  • Covariance and Contravariance on the same type argument

    - by William Edmondson
    The C# spec states that an argument type cannot be both covariant and contravariant at the same time. This is apparent when creating a covariant or contravariant interface you decorate your type parameters with "out" or "in" respectively. There is not option that allows both at the same time ("outin"). Is this limitation simply a language specific constraint or are there deeper, more fundamental reasons based in category theory that would make you not want your type to be both covariant and contravariant? Edit: My understanding was that arrays were actually both covariant and contravariant. public class Pet{} public class Cat : Pet{} public class Siamese : Cat{} Cat[] cats = new Cat[10]; Pet[] pets = new Pet[10]; Siamese[] siameseCats = new Siamese[10]; //Cat array is covariant pets = cats; //Cat array is also contravariant since it accepts conversions from wider types cats = siameseCats;

    Read the article

  • Linq Where Clauses - Better to stack or combine?

    - by burnt_hand
    When writing a method chain for LINQ, I can do the Where statements one of two ways: var blackOldCats = cats.Where(cat => cat.Age > 7 && cat.Colour == "noir" ) Or var blackOldCats = cats.Where(cat => cat.Age > 7).Where(cat.Colour == "noir" ) Are there any benefits of one over the other? Don't worry too much about the datatypes in this example, but if there are issues with datatypes, then that would be good to know too.

    Read the article

  • How to store date into Mysql database with play framework in scala?

    - by Rahul Kulhari
    I am working with play framework with scala and what am i doing : login page to login into web app sign up page to register into web app after login i want to store all databases values to user what i want to do: when user register for web app then i want to store user values into database with current time and date but my form is giving error. error: List(FormError(dates,error.required,List())),None) controllers/Application.scala object Application extends Controller { val ta:Form[Keyword] = Form( mapping( "id" -> ignored(NotAssigned:Pk[Long]), "word" -> nonEmptyText, "blog" -> nonEmptyText, "cat" -> nonEmptyText, "score"-> of[Long], "summaryId"-> nonEmptyText, "dates" -> date("yyyy-MM-dd HH:mm:ss") )(Keyword.apply)(Keyword.unapply) ) def index = Action { Ok(html.index(ta)); } def newTask= Action { implicit request => ta.bindFromRequest.fold( errors => {println(errors) BadRequest(html.index(errors))}, keywo => { Keyword.create(keywo) Ok(views.html.data(Keyword.all())) } ) } models/keyword.scala case class Keyword(id: Pk[Long],word: String,blog: String,cat: String,score: Long, summaryId: String,dates: Date ) object Keyword { val keyw = { get[Pk[Long]]("keyword.id") ~ get[String]("keyword.word")~ get[String]("keyword.blog")~ get[String]("keyword.cat")~ get[Long]("keyword.score") ~ get[String]("keyword.summaryId")~ get[Date]("keyword.dates") map { case id~blog~cat~word~score~summaryId~dates => Keyword(id,word,blog,cat,score, summaryId,dates) } } def all(): List[Keyword] = DB.withConnection { implicit c => SQL("select * from keyword").as(Keyword.keyw *) } def create(key: Keyword){DB.withConnection{implicit c=> SQL("insert into keyword values({word},{blog}, {cat}, {score},{summaryId},{dates})").on('word-> key.word,'blog->key.blog, 'cat -> key.cat, 'score-> key.score, 'summaryId -> key.summaryId, 'dates->new Date()).executeUpdate } } views/index.scala.html @(taskForm: Form[Keyword]) @import helper._ @main("Todo list") { @form(routes.Application.newTask) { @inputText(taskForm("word")) @inputText(taskForm("blog")) @inputText(taskForm("cat")) @inputText(taskForm("score")) @inputText(taskForm("summaryId")) <input type="submit"> <a href="">Go Back</a> } } please give me some idea to store date into mysql databse and date is not a field of form

    Read the article

  • Hibernate - One design problem

    - by Yatendra Goel
    I am learning Hibernate from the tutorial on JBoss website. I have a confusion in a code example located here. There is a Cat class code at 4.1. A simple POJO example. This Cat class has a reference to his mother as private Cat mother; Q1. If the class has an identifier property as id, then wouldn't it be better to store the cat's mother's id instead of cat's mother object. means instead of private Cat mother; wouldn't it be better to have private long motherId; `

    Read the article

  • [AS 3.0] How to use the string.match method to find multiple occurrences of the same word in a strin

    - by Steven
    In Actionscript and Adobe Flex, I'm using a pattern and regexp (with the global flag) with the string.match method and it works how I'd like except when the match returns multiple occurrences of the same word in the text. In that case, all the matches for that word point only to the index for the first occurrence of that word. For example, if the text is "cat dog cat cat cow" and the pattern is a search for cat*, the match method returns an array of three occurrences of "cat", however, they all point to only the index of the first occurrence of cat when i use indexOf on a loop through the array. I'm assuming this is just how the string.match method is (although please let me know if i'm doing something wrong or missing something!). I want to find the specific indices of every occurrence of a match, even if it is of a word that was already previously matched. I'm wondering if that is just how the string.match method is and if so, if anyone has any idea what the best way to do this would be. Thanks.

    Read the article

  • Openssh sftp-server: .filepart support?

    - by Guillaume Bodi
    I am trying to setup a SFTP server, running off Ubuntu Server 11.04. I installed openssh-server to provide SSH access. What I am trying to do is make file uploads run with a suffix (.filepart or whatever), which would be removed upon transfer completion. The flow idea is: User uploads cat.jpg The server starts writing cat.jpg.filepart in the destination directory Once the upload completes, the server trashes the previous cat.jpg (if any) and renames cat.jpg.filepart to cat.jpg This is to make sure that incomplete file uploads do not overwrite the existing files. Any idea on how I can do this? Thanks

    Read the article

  • sed problem with scripting

    - by Pablo Ramos
    I am trying to run a script using sed i runing like this for et in 1 # 2 3 do if [ -d ET$et ]; then rm -rf ET$et; fi mkdir ET$et cd ET$et cp $home/step_$i/FDE/diabatA/run.adf . cp $home/step_$i/FDE/diabatA/mas$i.xyz . awk1=`awk '/type=fde/{print NR }' run.adf | head -1` awk2=`$(echo "$a+379" | bc -l )` sed -n "$awk1,"$awk2"p" run.adf > first awk3=`awk '/ATOMS/{print NR +1}' first` awk4=`cat mas$i.xyz | wc -l` awk4=$( echo "$awk4-1" | bc -l ) awk5=`awk "/ATOMS/{print NR +"${awk4}" }" run.adf` sed -n "$awk3,"$awk4"p" first > atoms par=$( echo "$awk4-99" | bc -l ) rho1=$(cat atoms | head -34 ) rho2=$(cat atoms | head -64 | tail -31) rho3=$(cat atoms | head -97 | tail -33) rhoall=$(cat atoms | tail -${par} ) echo -e "$rho1\n$rho2\n$rhoall" > eje done but is telling me this: (standard_in) 1: syntax error sed: -e expression #1, char 6: unexpected `,' sed: -e expression #1, char 1: unknown command: `,' Please, I appreciate any help with this issue... Thanks Pablo

    Read the article

  • How to merge two .iso images

    - by pgrytdal
    I am following this tutorial to install Android onto my computer VIA Virtual Box. My problem is, they want you to download liveandroidv0.3.iso.001 liveandroidv0.3.iso.002 then they want you to merge these two files with cat liveandroidv0.3.iso.001 liveandroidv0.3.iso.002 > liveandroidv0.3.iso in the Terminal. The problem is, when I run the command, I get the following output cat liveandroidv0.3.iso.001 liveandroidv0.3.iso.002 > liveandroidv0.3.iso cat: liveandroidv0.3.iso.001: No such file or directory cat: liveandroidv0.3.iso.002: No such file or directory So, I was wondering if there was an alternative way to merge these files? Or if you guy's could help me merge them this way? Extra info: OS: Ubuntu 12.10 I downloaded the files to my /downloads folder in my home directory.

    Read the article

  • Functional programming compared to OOP with classes

    - by luckysmack
    I have been interested in some of the concepts of functional programming lately. I have used OOP for some time now. I can see how I would build a fairly complex app in OOP. Each object would know how to do things that object does. Or anything it's parents class does as well. So I can simply tell Person().speak() to make the person talk. But how do I do similar things in functional programming? I see how functions are first class items. But that function only does one specific thing. Would I simply have a say() method floating around and call it with an equivalent of Person() argument so I know what kind of thing is saying something? So I can see the simple things, just how would I do the comparable of OOP and objects in functional programming, so I can modularize and organize my code base? For reference, my primary experience with OOP is Python, PHP, and some C#. The languages that I am looking at that have functional features are Scala and Haskell. Though I am leaning towards Scala. Basic Example (Python): Animal(object): def say(self, what): print(what) Dog(Animal): def say(self, what): super().say('dog barks: {0}'.format(what)) Cat(Animal): def say(self, what): super().say('cat meows: {0}'.format(what)) dog = Dog() cat = Cat() dog.say('ruff') cat.say('purr')

    Read the article

  • Can I improve my AdWords quality scores with better landing pages?

    - by Eric
    I noticed that I have some keywords in my AdWords that are totally applicable to my site but the quality score of the keyword is 4 or 5. I'd like to get it up higher by creating custom versions of my site's home page (landing page) targeted specifically for people searching on those keywords. So for example, if we pretend my site sells pet food, my current home page has the phrase "dog food." I have a specific AdWords campaign for people searching on cat food (with cat food-specific ads). I'm thinking about changing the URL on those ads to something like http://mysite.com/cat.html, so a different home page comes up with the phrase "cat food." My thinking is that will help Google see that this new landing page is appropriate for the keywords and will raise my quality score for the "cat food" keywords. (Note that none of what I'm doing is shady or misleading; nobody would disagree that all of the keywords and ads I've created are perfect and appropriate for what my site offers.) Question: is what I describe the correct way to raise poor quality scores on keywords, and will it help?

    Read the article

  • looping .mpeg dump

    - by Matt Cook
    Need to dump an MPEG2 file in a loop, either to stdout or a named pipe. This works: $ { while : ; do cat myLoop.mpg; done; } | vlc - This works on a text file containing "1234\n": $ mkfifo myPipe $ cat test.txt > myPipe & < myPipe tee -a myPipe | cat - (it correctly loops, outputting "1234" on every line). Why does the following NOT work? $ cat myLoop.mpg > myPipe & < myPipe tee -a myPipe | vlc myPipe I'm primarily interested in re-writing the first statement to remove the improper "cat myLoop.mpg" statement. Will be inputting into VLC, or into FFMPEG and then piped into VLC.

    Read the article

  • CMD Command to create folder for each file and move file into folder

    - by Tom
    I need a command that can be run from the command line to create a folder for each file (based on the file-name) in a directory and then move the file into the newly created folders. Example : Starting Folder: Dog.jpg Cat.jpg The following command works great at creating a folder for each filename in the current working directory. for %i in (*) do md "%~ni" Result Folder: \Dog\ \Cat\ Dog.jpg Cat.jpg I need to take this one step further and move the file into the folder. What I want to achieve is: \Dog\Dog.jpg \Cat\Cat.jpg Can someone help me with one command to do all of this?

    Read the article

  • Determine which version of linux/unix/darwin I have

    - by John
    I have root ssh/terminal access to a linux server. How do I determine which version of centos I have? Some people suggested I run the command cat /etc/redhat-release but I got an error saying file not found. In fact, i'm not entirely sure i'm even using CentOS. That's what some suggested it might be. Here's a list of commands I tried that gave me no file or directory error: cat /etc/*release* cat /etc/*version* cat /proc/*version* cat /proc/*release* Here's a list of linux commands that do not exist: lsb_release: command not found wget: command not found yum: command not found

    Read the article

  • what data structure should I use for hash lookup as well as binary search?

    - by zebraman
    I am working on a school homework. I have a list of names. I want to be able to perform binary search on these names (find all names between a lower and upper bound) for first name as well as last name, and perform keyword searches as well (this will be accomplished using hashing. For example, if I have the names Garfield Cat Snoopy Dog Captain Crunch Fat Cat then a binary search of first names (C,H) will return Captain Crunch, Fat Cat, and Garfield Cat. A binary search of last names (Cr,D) will return Captain Crunch. A keyword search of 'cat' will return Fat Cat and Garfield Cat. I understand binary search will only work on a sorted list, but since I am planning on searching two different criteria, I will have to sort the list by last name or first name depending on what I'm searching for. I feel like it will be too inefficient to have to resort the list each time I want to perform a new binary search. Would it just be better for me to set up and maintain two sorted lists (one for sorted by first name, one for sorted by last name)? Also, for hashing, will I have to set up a different table of names for that as well? I understand each keyword will hash to some value determined by a hash function, and this value (or key) is a table address where the corresponding names are stored. So I just want to know what would be the best way to solve this problem? Maintaining separate structures, or is there a way to efficiently do everything I want with just one data structure?

    Read the article

  • MYSQL Merging 2 results into 1 table

    - by AlphaRomeo69
    Im building a c# program and am currently stuck at fetching data from MYSQL database and bind them to a grid view. I had been researching for a few days now but to no avail. I have 4 table in the database. table 1 - alpha table 2 - bravo table 3 - charlie table 4 - delta attributes of alpha (id, type, user, role ) attributes of bravo (id, type, date, user) attributes of charlie (id,type, cat, doneby, comment) atttibutes of delta (id,type, cat, doneby) * the pk of alpha and bravo is (id) * the pk of charlie and delta is (id, type) i did a query1 before by inner joinning alpha, bravo and charlie which leads to the sucessful result of (id, type, date, user, role, cat, doneby, comment) and i also did a query2 before by inner joinning alpha, bravo and delta which leads to the sucessful result of (id, type, date, user, role, cat, doneby) Right now, im trying to built a query3 which will merge the result from query1 and query2 together. the result of my attempts leads to (id, type, date, user, role, cat, doneby, comment,id, type, date, user, role, cat, doneby) As i do not want the repeated columns, I would like to seek advice on how to get the result to become like the one below by placing the records as a new tuple in the result table. (id, type, date, user, role, cat, doneby, comment) Thanks! P.S: the PK would not pose a problem due to (id, type)

    Read the article

  • Auto complete from database using CodeIgniter (Active Record)

    - by Ralph David Abernathy
    I have a form on my website in which one is able to submit a cat. The form contains inputs such as "Name" and "Gender", but I am just trying to get the auto completion to work with the "Name" field. Here is what my jquery looks like : $(document).ready(function() { $( "#tags" ).autocomplete({ source: '/Anish/auto_cat' }); }); Here is what my model looks like: public function auto_cat($search_term) { $this->db->like('name', $search_term); $response = $this->db->get('anish_cats')->result_array(); // var_dump($response);die; return $response; } } Here is my controller: public function auto_cat(){ $search_term = $this->input->get('term'); $cats = $this->Anish_m->auto_cat($search_term); } And here is my view: <head> <link rel="stylesheet" href="http://code.jquery.com/ui/1.10.3/themes/smoothness/jquery-ui.css" /> <script src="http://code.jquery.com/jquery-1.9.1.js"></script> <script src="http://code.jquery.com/ui/1.10.3/jquery-ui.js"></script> <link rel="stylesheet" href="/resources/demos/style.css" /> </head> <h1>Anish's Page</h1> <form action="/Anish/create" method="POST"> <div class="ui-widget"> <label for="tags">Name</label><input id="tags" type="text" name="name"> </div> <div> <label>Age</label><input type="text" name="age"> </div> <div> <label>Gender</label><input type="text" name="gender"> </div> <div> <label>Species</label><input type="text" name="species"> </div> <div> <label>Eye Color</label><input type="text" name="eye_color"> </div> <div> <label>Color</label><input type="text" name="color"> </div> <div> <label>Description</label><input type="text" name="description"> </div> <div> <label>marital status</label><input type="text" name="marital_status"> </div> <br> <button type="submit" class="btn btn-block btn-primary span1">Add cat</button> </form> <br/><br/><br/><br/> <table class="table table-striped table-bordered table-hover"> <thead> <tr> <th>Name</th> <th>Gender</th> <th>Age</th> <th>Species</th> <th>Eye Color</th> <th>Color</th> <th>Description</th> <th>Marital Status</th> <th>Edit</th> <th>Delete</th> </tr> </thead> <tbody> <?php foreach ($cats as $cat):?> <tr> <td> <?php echo ($cat['name']);?><br/> </td> <td> <?php echo ($cat['gender']);?><br/> </td> <td> <?php echo ($cat['age']);?><br/> </td> <td> <?php echo ($cat['species']);?><br/> </td> <td> <?php echo ($cat['eye_color']);?><br/> </td> <td> <?php echo ($cat['color']);?><br/> </td> <td> <?php echo ($cat['description']);?><br/> </td> <td> <?php echo ($cat['marital_status']);?><br/> </td> <td> <form action="/Anish/edit" method="post"> <input type="hidden" value="<?php echo ($cat['id']);?>" name="Anish_id_edit"> <button class="btn btn-block btn-info">Edit</button> </form> </td> <td> <form action="/Anish/delete" method="post"> <input type="hidden" value="<?php echo ($cat['id']);?>" name="Anish_id"> <button class="btn btn-block btn-danger">Delete</button> </form> </td> </tr> <?php endforeach;?> </tbody> </table> I am stuck. In my console, I am able to see this output when I type the letter 'a' if I uncomment the var_dump in my model: array(4) { [0]=> array(9) { ["id"]=> string(2) "13" ["name"]=> string(5) "Anish" ["gender"]=> string(4) "Male" ["age"]=> string(2) "20" ["species"]=> string(3) "Cat" ["eye_color"]=> string(5) "Brown" ["color"]=> string(5) "Black" ["description"]=> string(7) "Awesome" ["marital_status"]=> string(1) "0" } [1]=> array(9) { ["id"]=> string(2) "16" ["name"]=> string(5) "Anish" ["gender"]=> string(2) "fe" ["age"]=> string(2) "23" ["species"]=> string(2) "fe" ["eye_color"]=> string(2) "fe" ["color"]=> string(2) "fe" ["description"]=> string(2) "fe" ["marital_status"]=> string(1) "1" } [2]=> array(9) { ["id"]=> string(2) "17" ["name"]=> string(1) "a" ["gender"]=> string(1) "a" ["age"]=> string(1) "4" ["species"]=> string(1) "a" ["eye_color"]=> string(1) "a" ["color"]=> string(1) "a" ["description"]=> string(1) "a" ["marital_status"]=> string(1) "0" } [3]=> array(9) { ["id"]=> string(2) "18" ["name"]=> string(4) "Matt" ["gender"]=> string(6) "Female" ["age"]=> string(2) "80" ["species"]=> string(6) "ferret" ["eye_color"]=> string(4) "blue" ["color"]=> string(4) "pink" ["description"]=> string(5) "Chill" ["marital_status"]=> string(1) "0" } }

    Read the article

  • Assign a drive letter to a Solaris disk in a Windows box

    - by Cat
    I need some way to map a UFS Solaris drive (ie, assign a drive letter to it) while it is in a Windows XP box. I've found utilities that will let me transfer files from a Solaris disk to a NTFS disk on the Windows box, but nothing that will let me map/share that Solaris disk. And no, putting the Solaris disk in a Solaris box and using something like Samba to share the disk is unfortunately not an option. Cat

    Read the article

  • Why wont this entire word doc file generate from my php script?

    - by CheeseConQueso
    Here's the php script I'm using on a linux environment: <?php include("../_inc/odbcw.php"); //connect string $cat = $_GET["cat"]; if($_GET["st"]){$crs_query = "select crs_no, title, credits, abstr, prereq, coreq, lab_fee from xxx where active = 'Y' and cat = '".$cat."' and spec_top = 'Y' and prog='UNDG' order by crs_no";} else {$crs_query = "select crs_no, title, credits, abstr, prereq, coreq, lab_fee from xxx where active = 'Y' and cat = '".$cat."' and prog='UNDG' order by crs_no";} $crs_result = @mysql_query($crs_query); header("Content-type: application/vnd.ms-word"); header("Content-Disposition: attachment;Filename=cat.doc"); echo "<html>"; echo "<meta http-equiv=\"Content-Type\" content=\"text/html; charset=Windows-1252\">"; echo "<body>"; echo '<table border=0 width = 700>'; if($_GET["st"]){echo '<tr><td><font face=arial size=2><center>CATALOGUE<br>COURSE DESCRIPTIONS - '.$cat.'<br>SPECIAL TOPICS</center></font></td></tr>';} else {echo '<tr><td><font face=arial size=2><center>CATALOGUE<br>COURSE DESCRIPTIONS - '.$cat.'</center></font></td></tr>';} echo '</table>'; echo '<hr width=700>'; while($row = mysql_fetch_array($crs_result)) { $crs_no = $row['crs_no']; $title = $row['title']; $credits = $row['credits']; $abstr = $row['abstr']; $prereq = $row['prereq']; $coreq = $row['coreq']; $lab_fee = $row['lab_fee']; $rowspan = 2; if($prereq) {$rowspan++;} if($coreq) {$rowspan++;} if($lab_fee=="Y") {$rowspan++;} echo "<table border=0 width = 700>"; echo "<tr>"; echo "<td rowspan=".$rowspan." valign=top width=100><font face=arial size=2>".$crs_no."</font></td>"; echo "<td valign=top><font face=arial size=2><u>".$title."</u></font></td> <td valign=top align=right><font face=arial size=2>".$credits."</font></td>"; echo "</tr>"; echo "<tr>"; echo "<td colspan=2 valign=top align=justify><font face=arial size=2>".$abstr."</font></td>"; echo "</tr>"; if($prereq) { echo "<tr>"; echo "<td colspan=2 valign=top><font face=arial size=2>Prerequisite: ".$prereq."</font></td>"; echo "</tr>"; } if($coreq) { echo "<tr>"; echo "<td colspan=2 valign=top><font face=arial size=2>Coerequisite: ".$coreq."</font></td>"; echo "</tr>"; } if($lab_fee=="Y") { echo "<tr>"; echo "<td colspan=2 valign=top><font face=arial size=2>Lab Fee Required</font></td>"; echo "</tr>"; } echo "</table>"; echo "<br>"; } echo "</body>"; echo "</html>"; ?> Everything works fine before the inclusion of: header("Content-type: application/vnd.ms-word"); header("Content-Disposition: attachment;Filename=cat.doc"); echo "<html>"; echo "<meta http-equiv=\"Content-Type\" content=\"text/html; charset=Windows-1252\">"; echo "<body>"; These lines successfully bring up the dialogue box to open or save cat.doc, but after I open it, the only lines printed are: CATALOGUE COURSE DESCRIPTIONS - and the <HR> beneath this echoed text. It seems to go on lunch break for the while loop echoing section. Any ideas?

    Read the article

  • Source for 1Gbit Ethernet hub

    - by Cat
    I know I'm really reaching here, but does anyone know any source for a 1Gbit Ethernet hub? Not a router, not a switch, but a hub. I've been told by the Powers That Be that they shalt not allow any more switches on their network, any tie-ins must be via a hub. Yes, I know hubs have all sorts of issues, but I have no control over this. Cat

    Read the article

  • Bash mine script, please

    - by HomelyPoet
    The script, in and of its self, is fairly self-explanatory. Use if You so desire; any and all criticism wouldst be appreciated, as wouldst any suggestions for improvement. First iteration was writ upon OS X 10.5.8 Leopard, current iteration was run upon OS X 10.6.4 Snow Leopard with Safari 5.0.2 (6533.18.5). Also, any illumination as to why the first line ' if [ -f ] ' works, but ' if [ -f ~/Library/Safari/LocalStorage/*.localstorage ] ' generates an error? [yes, I am a bit of a Noob] Code: #! /bin/bash # SafariClear0.0.6 if [ -f ] then cat /dev/null > ~/Library/Safari/LocalStorage/*.localstorage rm -f ~/Library/Safari/LocalStorage/*.localstorage fi if [ -f ~/Library/Safari/LocalStorage/*.localstorage ] then echo "Oy vey!" fi cd ~/Library/Safari/ cat /dev/null > WebpageIcons.db cat /dev/null > TopSites.plist cat /dev/null > LocationPermissions.plist cat /dev/null > LastSession.plist cat /dev/null > History.plist echo "Clear" exit

    Read the article

  • how to run multiple shell scripts in parallel

    - by tom smith
    I've got a few test scripts, each of which runs a test php app. Each script runs forever. So, cat.sh, dog.sh, and foo.sh, each run a php script, and each shell script runs the php app in a loop, so it runs forever, sleeping after each run. I'm trying to figure out how to run the scripts in parallel, and at the same time, see the output of the php apps in the stdout/term window. I thought, simply doing something like foo.sh > &2 dog.sh > &2 cat.sh > &2 in a shell script would be sufficient, but it's not working. foo.sh, runs foo.php once, and it runs correctly dog.sh, runs dog.php in a never ending loop. it runs as expected cat.sh, runs cat.php in a never ending loop *** this never runs!!! it appears that the shell script never gets to run cat.sh. if i run cat.sh by itself in a separate window/term, it runs as expected... thoughts/comments

    Read the article

  • Why doesn't my symbolic link work?

    - by orokusaki
    I'm trying to better understand symbolic links... and not having very much luck. This is my actual shell output with username/host changed: username@host:~$ mkdir actual username@host:~$ mkdir proper username@host:~$ touch actual/file-1.txt username@host:~$ echo "file 1" > actual/file-1.txt username@host:~$ touch actual/file-2.txt username@host:~$ echo "file 2" > actual/file-2.txt username@host:~$ ln -s actual/file-1.txt actual/file-2.txt proper username@host:~$ # Now, try to use the files through their links username@host:~$ cat proper/file-1.txt cat: proper/file-1.txt: No such file or directory username@host:~$ cat proper/file-2.txt cat: proper/file-2.txt: No such file or directory username@host:~$ # Check that actual files do in fact exist username@host:~$ cat actual/file-1.txt file 1 username@host:~$ cat actual/file-2.txt file 2 username@host:~$ # Remove the links and go home :( username@host:~$ rm proper/file-1.txt username@host:~$ rm proper/file-2.txt I thought that a symbolic link was supposed to operate transparently, in the sense that you could operate on the file that it points to as if you were accessing the file directly (except of course in the case of rm where of course the link is simply removed).

    Read the article

  • Poor write performance on Debian server running NFS with 22TB exported JFS filesystem

    - by user143546
    I am currently running a debian server that is exporting a large JFS filesystem (22TB) over NFS (nfs-kernel-server.) When attempting to write to the NFS share, the performance is very poor. The 22TB disk is sitting on a NAS mounted using iSCSI. It will bust for a moment near expected line speed, and then sit idle for several seconds. Very little traffic measured in the low kb/sec. The wait peeks on write. When reading from the NFS mount, the system operates at expected speeds (11MB/sec). The issue does not occur when using SFTP, rsync, or local coping (non-nfs). The issue persists between stable and testing releases. On the same machine I have a 14TB ext4 filesystem using the exact same export configuration that does not share the issue. This share is not in regular use and thus not consuming resources. NFS Server: cat /etc/exports /data2 10.1.20.86(rw,no_subtree_check,async,all_squash) cat /sys/block/sdb/queue/scheduler noop [deadline] cfq cat /etc/default/nfs-kernel-server RPCNFSDCOUNT=8 RPCNFSDPRIORITY=0 RPCMOUNTDOPTS=--manage-gids NEED_SVCGSSD= RPCSVCGSSDOPTS= NFS Client: cat /etc/fstab 10.1.20.100:/data2 /root/incoming nfs rw,noatime,soft,intr,noacl 0 2 cat /sys/block/sdb/queue/scheduler noop [deadline] cfq cat /proc/mounts 10.1.20.100:/data2/ /root/incoming nfs4 rw,noatime,vers=4,rsize=262144,wsize=262144,namlen=255,soft,proto=tcp,port=0,timeo=600,retrans=2,sec=sys,clientaddr=10.1.20.86,minorversion=0,addr=10.1.20.100 0 0 This problem has me pretty stumped. Any help would be greatly welcomed. Thanks.

    Read the article

  • Microsoft signed driver appears as publisher not verfied

    - by Priyanka Gupta
    Task at hand: Microsoft sign drivers on Win 7. I microsoft signed my driver package 3 times every time thinking I might have missed a step or something. However, I cannot seem to get rid of the Windows Security error message "Windows can't verify the publisher of this driver software'. This is not the first time I have signed the driver packages. I was successfully able to sign other driver packages a few months ago. However, with this driver package I keep getting Windows security dialog box. Here's the procedure I follow - Create a new cat file using INF2CAT tool. Self sign the driver using a Versign Class 3 Public Primary Certification Authority - G5.cer. Run the microsoft tests on DTM Servers and clients with the devices that use this driver. Create WLK submission package. Self sign the cab file. Submit the package for certification. The catalog file that comes back after successfully passing tests says Name of signer "Microsoft Windows Hardware Comptibility Publisher". When I check the validity of signature using SignTool, it says the signature is vaild. However, when I try to install the driver with new signed catalog file the windows complain. Any ideas? Edit 11/12/2012: Reply to Eugene's comment Thanks for the help, Eugene. Yes. I did sign two other driver packages before. One of them was modified version of WinUSB driver. I am using the same certificate I used when I signed those two driver packages a few months ago. It costs $250 per signing from Microsoft. I would think that Microsoft would complain about it during certification if the certificate is wrong. I use the following command to self sign the CAT file. I don't have to specify the ceritificate name as there's only one certificate in the directory - Signtool sign /v /a /n CompanyName /t http://timestamp.verisign.com/scripts/timestamp.dll OurCatalogFile.cat Below is the result from running Verify command on the Microsoft signed OurCatalogFile.cat C:\Program Files\Microsoft SDKs\Windows\v7.1\Bin\x64signtool verify /v "C:\User s\logotest\Documents\serialdriversigning\OurCatalogFile.cat" Verifying: C:\Users\logotest\Documents\serialdriversigning\OurCatalogFile.cat" Hash of file (sha1): BDDF39B1DD95881B462164129758A7FFD54F47D9 Signing Certificate Chain: Issued to: Microsoft Root Certificate Authority Issued by: Microsoft Root Certificate Authority Expires: Sun May 09 18:28:13 2021 SHA1 hash: CDD4EEAE6000AC7F40C3802C171E30148030C072 Issued to: Microsoft Windows Hardware Compatibility PCA Issued by: Microsoft Root Certificate Authority Expires: Thu Jun 04 16:15:46 2020 SHA1 hash: 8D42419D8B21E5CF9C3204D0060B19312B96EB78 Issued to: Microsoft Windows Hardware Compatibility Publisher Issued by: Microsoft Windows Hardware Compatibility PCA Expires: Wed Sep 18 18:20:55 2013 SHA1 hash: D94345C032D23404231DD3902F22AB1C2100341E The signature is timestamped: Tue Nov 06 11:26:48 2012 Timestamp Verified by: Issued to: Microsoft Root Authority Issued by: Microsoft Root Authority Expires: Thu Dec 31 02:00:00 2020 SHA1 hash: A43489159A520F0D93D032CCAF37E7FE20A8B419 Issued to: Microsoft Timestamping PCA Issued by: Microsoft Root Authority Expires: Sun Sep 15 02:00:00 2019 SHA1 hash: 3EA99A60058275E0ED83B892A909449F8C33B245 Issued to: Microsoft Time-Stamp Service Issued by: Microsoft Timestamping PCA Expires: Tue Apr 09 16:53:56 2013 SHA1 hash: 1895C2C907E0D7E5C0292B92C6EA8D0E236F525E Successfully verified: C:\Users\logotest\Documents\serialdriversigning\OurCatalogFile.cat" Number of files successfully Verified: 1 Number of warnings: 0 Number of errors: 0 Thank you!

    Read the article

< Previous Page | 1 2 3 4 5 6 7 8 9 10 11 12  | Next Page >