I recently tried to install CoffeeScript on my mac and now am unable to use even the most basic of commands like ls, cd and so on. Something tells me that it's because the $PATH variable has changed. I remember having to do that when I tried to make the installation. I tried following the instructions found , but it doesn't work because the vi command isn't found.  Upon entering echo $PATH in the terminal, it reads /usr/local/bin:
I'm really new to Mac OSX and UNIX based systems. I wanted to run a few Windows games on my Mac Mini so I started installing Wine and MacPorts. I think the installs are correct, but when I type sudo port install wine I see a not found error in my terminal. I tried other basic commands like say and clear and all of them return the same not found error. My research shows that my PATH might be incorrectly set, but it lacks steps I can implement. Specifically, I ran this command: echo $PATH and it returned:  /opt/local/bin:/opt/local/sbin:/opt/local/bin:/opt/local/sbin:/opt/local/bin  I'm a complete newbie to mac and have no idea where .bash_profile or any of those files are. My skills let me install Xcode and the Command Line tools for Xcode and I sense I need to level up on path management. At this point I need help managing my dot files and changing my path to fix these specific errors on Mountain Lion. What are my next steps?
Windows Power Options Clarification So I was looking through the Windows 7 power options via Control Panel today, and I realized I had a couple of unresolved questions as to the nature of various choices. I was wondering if someone could give me a clear and concise explanation of the difference between the following four selections:   Sleep Mode Hibernate Mode Standby Mode Turn off hard disks after...   For example, regarding option 4 - does this mean that after the elapsed time limit, the computer will go into standby, hibernate, sleep, or just turn off? Below is an image of the options (albeit on a Windows XP system, but I think the same concepts should apply): Statistics  () In Q1 of 2012 - 0.0134 such comments per question (~1.33%) In Q2 of 2012 - 0.0167 such comments per question (~1.66%) In Q3 of 2012 - 0.0169 such comments per question (~1.68%) In Q4 of 2012 - 0.0193 such comments per question (~1.92%) In Q1 of 2013 - 0.0223 such comments per question (~2.22%)  The vast majority of these questions need serious help.  Unfortunately, there is a growing trend towards abuse Along with the good, comes some bad -- as usual in life. These comments are bad when  Posting &quot;what have you tried&quot; multiple times per question is severely obnoxious Posting &quot;what have you tried&quot; when the user has clearly shown that they have tried to solve it on their own  It is becoming increasingly common to see &quot;what have you tried?&quot; comments in these scenarios. Some examples     Workarounds Flagging Comments - It is considered a good thing to be liberal with comment flagging -- that helps us clean up after the fact. &quot;Too Chatty&quot; is a no-brainer here. Unfortunately, that only cleans up after the damage has been done. All signs point toward the continued increase of the trend of using &quot;what have you tried&quot; comments. I spend a lot of time editing and cleaning up bad questions. This trend came up on my radar toward the end of last year and it is getting worse. So, I thought at the very least that I'd raise some awareness. Can I combine extension tubes and macro filters at once to give better macros? pgfplots: correct rounding problems I had a problem with disappearing marker as the data sum up to more than 100 while xmax was set to 100. See .  As written in the answer to the cited question I tried to avoid the problem by normalizing the value to 100. But this lead to (much smaller) rounding errors in previously correct rows and now the marker disappear there. See the following example. Before the normalisation the column F ist affected, after the column B.   How can I in a reliable way avoid this rounding problem? Or at least get a clear error message. I have quite a number of this plots and I don't want to have to check them all the time for missing markers.    \documentclass{scrreprt} \usepackage{pgfplots} \pgfplotsset{compat=1.13} \usepackage{pgfplotstable} \pgfplotsset{  my stackbar plot/.style={              xbar stacked,              xmin=0,xmax=100,              symbolic y coords={A,B,C,D,E,F,G},              ytick=data,              nodes near coords={xxx},}}  \begin{document}  \pgfplotstableread[col sep=space]{  text   --  -    +       ++  A      0.0 1.7 13.8    84.5  B      0.0 0.6 20.1    79.3  C      0.0 1.9 13.2    84.9  D      0.0 1.6 27.9    70.5  E      1.3 3.9 19.5    75.3  F      0.0 1.4 15.0    83.7  G      0.3 1.7 24.8    73.2  }\data   \pgfplotstablecreatecol[create col/expr={\thisrow{--}+\thisrow{-}+\thisrow{+}+\thisrow{++}}]{sum}\data %  \pgfplotstablecreatecol[create col/copy=--]{--o}\data  \pgfplotstablecreatecol[create col/copy=-]{-o}\data  \pgfplotstablecreatecol[create col/copy=+]{+o}\data  \pgfplotstablecreatecol[create col/copy=++]{++o}\data  \pgfplotstablecreatecol[create col/expr={100/\thisrow{sum}*\thisrow{--o}}]{--}\data  \pgfplotstablecreatecol[create col/expr={100/\thisrow{sum}*\thisrow{-o}}]{-}\data  \pgfplotstablecreatecol[create col/expr={100/\thisrow{sum}*\thisrow{+o}}]{+}\data  \pgfplotstablecreatecol[create col/expr={100/\thisrow{sum}*\thisrow{++o}}]{++}\data  \pgfplotstablecreatecol[create col/expr={\thisrow{--}+\thisrow{-}+\thisrow{+}+\thisrow{++}}]{sumnew}\data  \pgfplotstabletypeset[columns={text,sum}   ,precision=10,columns/text/.style={string type}]\data \quad \pgfplotstabletypeset[columns={text,sumnew},precision=10,columns/text/.style={string type}]\data   %\pgfplotstablesave{\data}{pgfplotstempout.dat} \begin{tikzpicture} \begin{axis}[my stackbar plot]  \addplot table [x expr = \thisrow{--o},y=text] {\data};  \addplot table [x expr = \thisrow{-o}, y=text] {\data};  \addplot table [x expr = \thisrow{+o}, y=text] {\data};  \addplot table [x expr = \thisrow{++o}, y=text] {\data}; \end{axis} \end{tikzpicture} \quad \begin{tikzpicture} \begin{axis}[my stackbar plot]  \addplot table [x expr = \thisrow{--},y=text] {\data};  \addplot table [x expr = \thisrow{-}, y=text] {\data};  \addplot table [x expr = \thisrow{+}, y=text] {\data};  \addplot table [x expr = \thisrow{++}, y=text] {\data}; \end{axis} \end{tikzpicture}  \end{document} The  spell says time stops for other creatures.  What all is affected by the spell? Is gravity affected? Air movement?  I know that the spell only does what it says, and nothing else, but just wondering.   In addition, is it saying that the other creatures are not affected by environmental effects and the like while time is stopped?  For instance, if a wind blew really hard at one of the creatures you're fighting, would it affect that foe while time stop is active? If you were to place a bear trap behind the person, and a hard wind blew enough to tip them, would they then fall over onto the bear trap and be damaged without the spell ending?  This is a very curious spell... When to use an object pronoun or a possessive adjective before a gerund The rule says that we can use a possessive adjective or an object pronoun before a gerund. Is there a rule  that says when to use each or are they interchangeable? Some say that it's wrong to use an object pronoun before a gerund. Zoom in/out on click in OpenLayers 3? What's the term for design ala "object.method1().method2().method3()"? What's the term for this design?  object.method1().method2().method3()   ..when all methods return *this?  I found the term for this a while ago, but lost it meanwhile. I have no clue how to search for this on google :) Also if anyone can think of a better title for the question, feel free to change it.  Thanks  Update-Gishu: After reading about it, I feel that your question is misleading w.r.t. code snippet provided.. (Feel free to rollback)  Method Chaining  object.method1().method2().method3()   Fluent Interfaces  private void makeFluent(Customer customer) {         customer.newOrder()                 .with(6, "TAL")                 .with(5, "HPK").skippable()                 .with(3, "LGV")                 .priorityRush();     } What does "end to end" mean in deep learning methods? Change paper size in mid-document My document should be letterpaper and my attachments should be a4paper. I had high hopes for the \newgeometry command from the geometry package, but the documentation says      \newgeometry is almost similar to   \geometry except that \newgeometry   disables all the options specified in   the preamble and skips the   papersize-related options: landscape,   portrait and paper size options (such   as papersize, paper=a4paper and so   forth).   Any help is appreciated! Why aren't Christoffel symbols tensors? - asked from a fibre bundle perspective I have the following code that will remove lines with the pattern banana and 2 lines after it:  sed '/banana/I,+2 d' file   So far, so good! But I need it to remove 2 lines before banana, but I can't get it with a “minus sign” or whatever (similar to what grep -v -B2 banana file should do but doesn't):  teresaejunior@localhost ~ &gt; LC_ALL=C sed '-2,/banana/I d' file sed: invalid option -- '2' teresaejunior@localhost ~ &gt; LC_ALL=C sed '/banana/I,-2 d' file sed: -e expression #1, char 16: unexpected `,' teresaejunior@localhost ~ &gt; LC_ALL=C sed '/banana/I,2- d' file sed: -e expression #1, char 17: unknown command: `-' Search and replace a line in a file in Python I want to loop over the contents of a text file and do a search and replace on some lines and write the result back to the file. I could first load the whole file in memory and then write it back, but that probably is not the best way to do it.  What is the best way to do this, within the following code?  f = open(file) for line in f:     if line.contains('foo'):         newline = line.replace('foo', 'bar')         # how to write this newline back to the file Shut down computer from keyboard Is there a keyboard shortcut available to shutdown the computer?  I know I can use the Power button, but I would like to be able to it from the keyboard.  If such a shortcut does not exist already, how do I set one? Formal proof for $q \land \neg q \vdash r \land \neg r$ How do I get Gmail to ask me to be a mailto handler again? How do I fix a NoSuchMethodError? How to install latest HPLIP on my Ubuntu to support my HP printer and/or scanner? What are the alternatives to Socket Programming? I was browsing around for programming troubleshooters, and I was wondering what the alternate would be for Socket Programming; if there is one. "They are quite full up this year."