Hi this is my first time writing bash and I'm trying to practice creating a bash script and am attempting to do the following:    Using absolute path the script changes directory to your home directory. Next it verifies whether a subdirectory called project exists. If it does not exist it creates that directory. Next it changes directory moving into the project subdirectory using relative path.   I'm already stuck on the first step:  #!/bin/bash cd if [ -d ./project ]     then          echo hi it exists!     else         echo it doesn't exist! cd project/   I would appreciate if someone could help! thank you so much!
I'm trying to write a small script to change the current directory to my project directory:  #!/bin/bash cd /home/tree/projects/java   I saved this file as proj, added execute permission with chmod, and copied it to /usr/bin. When I call it by: proj, it does nothing. What am I doing wrong?
What CMYK values should I use for rich black, and how should I handle tints/shades? I'm working on a full color piece in Illustrator which has a few large black and grey areas.  I'd like the black to be a rich black. I was thinking c30 m30 y30 k100. What is the best ways to match my gray areas? Where is it preferred to place the answer to duplicate questions? A similar task for changing the desktop background, can be achieved using the following script:   FILE="/backgrounds/background.png" gsettings set org.gnome.desktop.background picture-uri "$FILE"   How would I achieve the same result, but with the user's avatar/profile picture? Gmail App in my Android device shows correctly all the labels that I created using Gmail through web interface.  Can I create new labels in Gmail on Android device using Gmail App?   Also, ideally, once I create these new labels in Gmail App, I obviously should be seeing the same in Web Interface of Gmail too (Sync!!).  Any ideas? /oracle/GR1/121/bin/sqlplus / as sysdba &lt;&lt;EOF &gt;&gt; $LOGFILE whenever sqlerror exit sql.sqlcode; set echo on; set serveroutput on; STARTUP; EXIT EOF   Already tried it with the path, but it hasn't worked. What does the dot mean On my reelbox (running Ubuntu) I have found a file in /etc/init that contains the following  # frontpanel-pre - check for frontpanel CAPs and adjust time #  description     "check frontpanel caps"  #start on starting mountall #start on tty-device-added DEVNAME=/dev/ttyS0  task  script         (         /sbin/dev_frontpanel.sh         /sbin/reelfpctl -capability         ) &gt; /dev/.frontpanel.caps         initctl emit --no-wait frontpanel-linked end script   I wonder if the dot in /dev/.frontpanel has some special meaning in linux  I thought the output of the commands in the brackets will be written to a file called ".frontpanel.caps" in /dev/ but there is no such file. In /dev/ there is a frontpanel which is a link to /dev/ttyS0  Could it be, that e.g. echo something &gt; /dev/.frontpanel.caps actually sends data (something in this case) to /dev/frontpanel ?  What does .caps do then? I have a figure that is wider than the \textwidth of my document. (I don't want to change the \textwidth.) As a result, the leftmost part of the figure is flush with the left margin, while the rightmost part spills into the right margin too much. I'd like to center the figure, so that it will exceed the \textwidth equally on both sides. Related questions with over 99 score display incorrectly LuaLaTeX protrusion problem with Negative value Cosine of the sum of two solutions of trigonometric equation $a\cos \theta + b\sin \theta = c$ Question: If $\alpha$ and $\beta$ are the solutions of $a\cos \theta + b\sin \theta = c$, then show that: $$\cos (\alpha + \beta) = \frac{a^2 - b^2}{a^2 + b^2}$$  No idea how to even approach the problem. I tried taking two equations, by substituting $\alpha$ and $\beta$ in place of $\theta$ in the equation and manipulating them, but that didn't get me anywhere. Please help! Normalizing the final weights vector in the upper bound on the Perceptron's convergence The convergence of the "simple"  says that:  $$k\leqslant \left ( \frac{R\left \| \bar{\theta} \right \|}{\gamma } \right )^{2}$$  where $k$ is the number of iterations (in which the weights are updated), $R$ is the maximum distance of a sample from the origin, $\bar{\theta}$ is the final weights vector, and  $\gamma$ is the smallest distance from $\bar{\theta}$ to a sample (= the margin of hyperplane).  Many books implicitly say that  $\left \| \bar{\theta} \right \|$ is equal to 1. But why do they normalize it ? To what extent is WhatsApp's statement on secure messaging realistic? What experiment would disprove string theory? What are good strategies for booster drafts? I know that doing a booster draft can be somewhat complicated, because to really be good you need to know a lot about the set you're drafting (or be really good at evaluating cards quickly) and to pay attention to signal cards.    Besides going into the whole complicated strategies of knowing the set and paying attention to signal cards, what are some relatively simple/basic guidelines for drafting? for a $3 \times 3$ matrix A ,value of $ A^{50} $ is I f $$A= \begin{pmatrix}1&amp; 0 &amp; 0 \\  1 &amp; 0 &amp; 1\\ 0 &amp; 1 &amp; 0 \end{pmatrix}$$  then $ A^{50} $  is   $$ \begin{pmatrix}1&amp; 0 &amp; 0 \\  50 &amp; 1 &amp; 0\\ 50 &amp; 0 &amp; 1 \end{pmatrix}$$ $$\begin{pmatrix}1&amp; 0 &amp; 0 \\  48 &amp; 1 &amp; 0\\ 48 &amp; 0 &amp; 1 \end{pmatrix}$$ $$\begin{pmatrix}1&amp; 0 &amp; 0 \\  25 &amp; 1 &amp; 0\\ 25 &amp; 0 &amp; 1 \end{pmatrix}$$ $$\begin{pmatrix}1&amp; 0 &amp; 0 \\  24 &amp; 1 &amp; 0\\ 24 &amp; 0 &amp; 1\end{pmatrix}$$   I am stuck on this problem. Can anyone help me please............... Is there a way to remove sites permanently from (my personal) Google search results? I regularly find sites that copy content from elsewhere (mailing lists, etc) while not providing any added value. Quite to the contrary, they are pretty heaped with ads.  I'd like to remove those sites as permanently as possible from my Google search results. Any ideas? The third formula on the  states that $$\varphi (mn) = \varphi (m) \varphi (n) \cdot \dfrac{d}{\varphi (d)} $$ where $d = \gcd(m,n)$.  How is this claim justified?  Would we have to use the Chinese Remainder Theorem, as they suggest for proving that $\varphi$ is multiplicative? I've started using the dashicon fonts in my theme options page for WP 3.8+ users. To take care of users on &lt; 3.8, I've added the dashicon fonts to my theme folder and also an entry at the top of my custom admin stylesheet:  @font-face {     font-family: 'dashicons';     src: url('fonts/dashicons.eot'); }  @font-face {         font-family: 'dashicons';         src: url(data:application/x-font-woff;charset=utf-8;base64,xxx) format('woff'),         url('fonts/dashicons.ttf') format('truetype'),         url('fonts/dashicons.svg#dashicons') format('svg');     font-weight: normal;     font-style: normal; }   (I've left out the base64 encode for brevity)  This works great, however, I'm getting a bit of strange behavior with the fonts. When I leave the admin open in a tab and go away for a bit, then come back, every once in a while, the webfonts have turned to squares, as if the font is missing.  This does not happen every time. It appears to be somewhat random.  In those cases, simply doing a mouseover the page usually returns the webfonts to their proper symbols.  The screenshots below show the issue. The first screenshot is what I see when the problem occurs. The second screenshot is what I'm expecting to see when things go well.   Notice in the first shot, how the wordpress labels themselves have gone to a default serif font. How do you make HDDs and partitions mount at startup on Ubuntu?  I always keep my media and data files on separate partitions - one 2tb HDD and a 400 odd gig partition.  I have been trying to swap the default folder location for the home directory to my other drives.  It works when I change the /home/user_name/.config/user-dirs.dirs file to the directories I want, but only until I reboot the system. I am only assuming that the drives not mounting is the problem with it, but it would be helpful either way.  If any one knows another reason for why the directories change back to default each time that would be good also. $G$ is the set of all subsets of a set $A$, under the operation of $\triangle\;$: Symmetric Difference of sets.  $A$ has at least two different elements.  I need to check if this is a group, and if it does to show if the group is abelian and/or finite.  Associativity - easy from Symmetric Difference. Identity element - empty group. Inverse element - each element is inverse to itself. Am I right?  abelian? finite?