I am trying to set up a cronjob to run on the last sunday of each month. This is what I have accomplished. Right now, it is running every sunday at 10 PM. 0 22 * * 0 /usr/basys_bin/clean_cups_cache.sh
I want to schedule my script for last Saturday of every month. I have come up with the below:  45 23 22-28 * *  test $(date +\%u) -eq 6 &amp;&amp; echo "4th Saturday"  &amp;&amp; sh  /folder/script.sh    Is this correct or I need to change it? I can't test it right now as it will be invoked only on last saturday. Please advise.  I have the below for last sunday of every month but i can't understand much of it. The first part gives 24 which is sunday and after -eq gives 7 which i don't know what it means:  00 17  * * 0 [ $(cal -s | tail -2 | awk '{print $1}') -eq $(date | awk '{print $3}') ] &amp;&amp; /folder/script.sh   Can i modify the above to get last saturday?  With Romeo's help I was help to come up with the below answer:  00 17 * * 6 [ $(cal -s | tail -2 | awk '{print $7}') -eq $(date | awk '{print $3}') ] &amp;&amp; /folder/script.sh
Get Label value for specified language When —the bartender at the Cantina at Mos Eisley spaceport in the first Star Wars—says:     “We don’t serve their kind here.”   In reference to C-3PO and R2-D2 entering the bar, it’s certainly a bit prejudicial, but are these commonly held views in this universe? We don’t see it happen anywhere else in the films but is it implied elsewhere? Is there a single word for a "friend of a friend"? I am looking for a word that I could use instead of "friend of a friend". On certain occasions, it happens that you may want to talk about a friend of a friend with someone else.   In such cases how would you refer to this friend? How do I change the location of macOS screen captures? As a developer, I take a lot of screen captures. I often take screen shots to share with Stack Exchange members in chat.  The problem is my Desktop is so cluttered with screen captures that they're now overlapping! I'd like to save all screenshots in a dedicated folder or directory.  In macOS, how do I change the default location where screen captures are saved?  These are the screen shots taken with CommandShift3 or CommandShift4 keyboard shortcuts.  I would prefer a solution which doesn't require installing any software. 13.04 - more than four workspace shortcuts in GNOME Flashback (No effects) I'm using GNOME Flashback (No effects) on Ubuntu 13.04 and I've got six workspaces however when entering System Settings -> Keyboard -> Shortcuts -> Navigation I only see options to address the initial four.  It used to be options up to 12 workspaces there and as I certainly don't need that much, I want to have at least enough for the amount currently active.  How can I restore or add more shotcuts specifically to navigate and move windows to workspace 5 and 6? What are good ways to make pdflatex output copy-and-pasteable? How to use triangle inequality to establish Reverse triangle inequality I need to use $|a+b| \leq |a|+|b|$ to show that $||a|-|b|| \leq |a-b|$ .   I have tried to represent  $||a|-|b||$ as  $||a|+(-|b|)|$ , and then get $||a|+(-|b|)| \leq |a|+|-|b||$ , but that isn't leading me anywhere given $|a-b| \leq |a|+|b|$. Currently, Stack Exchange’s Markdown parser only allows four-space indents to represent code blocks:      // some code     // another line of code    and other Markdown implementations allow for an alternative syntax, that doesn’t require indenting each code line:  ``` // some code // another line of code ```   This is much more convenient to type out. It would be super useful if Stack Exchange could support this syntax.    By extension, this syntax also allow you to specify the source language right after the opening ```:  ```js // some code // another line of code ```   …which would then enable syntax highlighting for that specific language. Although it’s interesting metadata, I don’t think this feature is needed on Stack Overflow, as the syntax highlighting library works pretty well for various languages.  So, even if you would allow this syntax but ignore the ```language, this would greatly improve my productivity on Stack Exchange.  What do you think?  The moderators are currently collecting feedback regarding this feature, so please post a comment with your thoughts. Good idea? Bad idea? Don’t really care? What do you think are the benefits/drawbacks? Experiences? Let them know! Thanks! RegEx for matching UK Postcodes How can I make a script that opens terminal windows and executes commands in them? I have three scripts I need to run when I start up my Ubuntu machine, they start services I use in my development environment.  To do that, I manually open three terminals and type in the commands.  Is there any way to create a script that will open three terminals and execute one command in each of these? (Each command should be in a separate terminal window so I can see their output). Different results for integration using Mathematica and MATLAB Prove linear combinations of logarithms of primes over $\mathbb{Q}$ is independent Suppose we have a set of primes $p_1,\dots,p_t$. Prove that  $\log p_1,\dots,\log p_t$ is linear independent over $\mathbb{Q}$. Now, this implies $ \sum_{j=1}^{t}x_j\log(p_j)=0 \iff x_1=\dots=x_t=0$.  I think I have to use that fact that every $q\in\mathbb{Q}$ can be written as $\prod_{\mathcal{P}}$, where $n_p$ is a unique sequence ($n_2$,$n_3$,$\dots$) with domain $\mathbb{Z}$. Here, $\mathcal{P}$ denotes the set of all integers.  Now how can I use this to prove the linear independency? I am using QGIS 3.2.0 on a Mac (and also have QGIS 2), and I have a fishnet grid (probably created in Arc) that comprises of nearly 2 million grid cells. As a result, every change I make to the attribute table takes hours, so I can't experiment as I would usually.  I need to label each grid cell such that the north-westernmost cell is "1", and the numbers proceed by rows, until the last number goes into the south-easternmost cell. Using the row-number doesn't work, as that's not how the table is sorted. I've done this before, but cannot remember how. It would be nice to allow users to mark a change in an answer (or question) as minor (e.g. for a simple spelling or grammar correction). A change marked as minor wouldn't push the question on top of the list of questions on the home page or in the feeds. It wouldn't trigger any notification. This could be implemented with a "Minor change" checkbox when editing an entry (a la Confluence). What do you think? Cooking away alcohol When you cook with wine or spirits, when does the alcohol cook away? Obviously high temperatures will do it, but how low of temperatures will work? Also, does it vary by the type of alcohol? Mac equivalent of Ctrl + Space to select an item on a list I want to select non-consecutive items on a list, without using a mouse/trackpad - there should be no clicks involved.  In Windows and Linux (at least Ubuntu) an item can be selected using Space/ button, which, in combination with arrows and Ctrl key allows me to select multiple items in any environment (file manager, IDE etc.) - e.g.  Enter a directory -> hold Ctrl -> down arrow twice -> press Space -> down arrow twice -> press Space.  Now I should have items 1, 3 and 5 selected. Is there a way to do the same thing in OS X?  PS. Sorry for such a verbose description, but so far every answer I encountered advices using Command + Click, and this is something I don't want to do. Computing $ \lim_{n\rightarrow \infty}\left(\frac{1^n+2^n+\cdots \cdots +n^n}{n^n}\right)$ Can I travel to Australia in less than 2 weeks if I transfer my visa to my new passport? I transferred my visa to my new passport and it’s saying it takes 2 weeks to come, my flight is Sunday I arrive in Sydney Monday at night, I still have my old passport! If I bring that will they let me go into the country because my new one literally arrived two days ago! And the visa will be transferred in 2 weeks! Will I have to push my flight or will I be left? Correcting for multiple kruskal wallis tests Mail vs. mail what is the difference What is this business about mail and Mail? [On a CentOS box] Why mail does not work but won't return an error either while Mail works fine with the exact same syntax?  Mail is basically a link to mail, isn't it?  Sorry, this was a mixup, apparently (for historical reasons?!) there is a mail and a Mail  Nowadays it looks like they both point to the same thing, on my machine:  sr-linux&gt; ls -l `which mail` -rwxr-xr-x    1 root     mail        66492 Jun 24  2001 /bin/mail sr-linux&gt; ls -l `which Mail` lrwxrwxrwx    1 root     root           14 Nov 19  2001 /usr/bin/Mail -&gt; ../../bin/mail