I was trying to upgrade the PHP packages on my Ubuntu 14.04 LTS server and I keep getting errors. I know there is a duplicate of this Qn but i removed the error causing file from /var/cache/apt/archives/ but it did not work.  I ran these commands:  sudo apt-add-repository ppa:ondrej/php5 sudo apt-get autoremove sudo apt-get update sudo apt-get -f install   Then I got this:  Reading package lists... Done Building dependency tree        Reading state information... Done Correcting dependencies... Done The following packages will be REMOVED:   apache2-mpm-prefork apache2.2-bin apache2.2-common php5-dev php5-gd The following NEW packages will be installed:   apache2-bin apache2-data libjson-c2 php5-json php5-ssh2 The following packages have been kept back:   libgd2-xpm-dev libssl-dev openssl The following packages will be upgraded:   apache2 libssh2-php php-pear php5 php5-cli php5-common php5-curl php5-fpm php5-mcrypt php5-mysql 10 upgraded, 5 newly installed, 5 to remove and 3 not upgraded. 1 not fully installed or removed. Need to get 375 kB/8007 kB of archives. After this operation, 2457 kB disk space will be freed. Do you want to continue [Y/n]? y Get:1 http://ppa.launchpad.net/ondrej/php5/ubuntu/ precise/main php-pear all 5.5.30+dfsg-1+deb.sury.org~precise+1 [373 kB] Get:2 http://ppa.launchpad.net/ondrej/php5/ubuntu/ precise/main php5 all 5.5.30+dfsg-1+deb.sury.org~precise+1 [1220 B] Fetched 375 kB in 0s (1074 kB/s) perl: warning: Setting locale failed. perl: warning: Please check that your locale settings:     LANGUAGE = "en_US:en",     LC_ALL = (unset),     LC_CTYPE = "UTF-8",     LANG = "en_US.UTF-8"     are supported and installed on your system. perl: warning: Falling back to the standard locale ("C"). locale: Cannot set LC_CTYPE to default locale: No such file or directory locale: Cannot set LC_ALL to default locale: No such file or directory (Reading database ... 96522 files and directories currently installed.) Unpacking apache2-bin (from .../apache2-bin_2.4.16-4+deb.sury.org~precise+4_amd64.deb) ... dpkg: error processing /var/cache/apt/archives/apache2-bin_2.4.16-4+deb.sury.org~precise+4_amd64.deb (--unpack):  trying to overwrite '/usr/share/man/man8/apache2.8.gz', which is also in package apache2.2-common 2.2.22-1ubuntu1.10 dpkg-deb (subprocess): subprocess data was killed by signal (Broken pipe) dpkg-deb: error: subprocess &lt;decompress&gt; returned error exit status 2 Processing triggers for man-db ... Errors were encountered while processing:  /var/cache/apt/archives/apache2-bin_2.4.16-4+deb.sury.org~precise+4_amd64.deb E: Sub-process /usr/bin/dpkg returned an error code (1)
For example:  $ sudo apt-get install curl Reading package lists... Done Building dependency tree Reading state information... Done You might want to run 'apt-get -f install' to correct these: The following packages have unmet dependencies: bsh : Depends: libjline-java but it is not going to be installed groovy : Depends: libjline-java but it is not going to be installed rhino : Depends: libjline-java but it is not going to be installed E: Unmet dependencies.   Try 'apt-get -f install' with no packages (or specify a solution).   I get the same or similar errors when I attempt to install clojure1.3, leiningen, and several other packages.   When I try the suggestion made in the error message, this is what happens:  $ sudo apt-get -f install  Reading package lists... Done Building dependency tree        Reading state information... Done Correcting dependencies... Done The following packages were automatically installed and are no longer required:   diffstat linux-headers-3.2.0-26-generic linux-headers-3.2.0-26 dh-apparmor dkms html2text libmail-sendmail-perl libsys-hostname-long-perl Use 'apt-get autoremove' to remove them. The following extra packages will be installed:   libjline-java Suggested packages:   libjline-java-doc The following NEW packages will be installed:   libjline-java 0 upgraded, 1 newly installed, 0 to remove and 0 not upgraded. 23 not fully installed or removed. Need to get 0 B/72.0 kB of archives. After this operation, 129 kB of additional disk space will be used. Do you want to continue [Y/n]? Y (Reading database ... 226243 files and directories currently installed.) Unpacking libjline-java (from .../libjline-java_1.0-1_all.deb) ... dpkg: error processing /var/cache/apt/archives/libjline-java_1.0-1_all.deb (--unpack):  trying to overwrite '/usr/share/java/jline.jar', which is also in package scala 2.9.2-400 Errors were encountered while processing:  /var/cache/apt/archives/libjline-java_1.0-1_all.deb E: Sub-process /usr/bin/dpkg returned an error code (1)  $ sudo apt-get upgrade Reading package lists... Done Building dependency tree        Reading state information... Done You might want to run 'apt-get -f install' to correct these. The following packages have unmet dependencies:  bsh : Depends: libjline-java but it is not installed  groovy : Depends: libjline-java but it is not installed  rhino : Depends: libjline-java but it is not installed E: Unmet dependencies. Try using -f.
Can I use the Stack Exchange concept in my own sites? I am thinking of making a site which will have a forum. I already have a lot of users (in an old forum, which I want to renew).  I like the Stack Exchange concept (voting, reputation, etc).  Can I build one of my own on my site? (I don't intend to copy any source code, just the concept itself.)  Is the concept patented or otherwise legally protected, or is it free to use? This example illustrates some conflict between xelatex and natbib- and footnote-generated superscripts.  The semi-colon between distinct citations is not typeset as a superscript, nor is the dagger.  The asterisk, however, looks fine to me.  Any suggestion on how to make these auto-generated superscripts look more normal?   Update Mostly fixed, see second screenshot below.  Update 2 Fully fixed!  Alter the MWE below with this code:  \DefineFNsymbols*{safestar}{{$*$}{\textdagger}{\textdaggerdbl}{\textsection} {\textparagraph}{\textbardbl}{$**$}{\textdagger\textdagger} {\textdaggerdbl\textdaggerdbl}{\textsection\textsection} {\textparagraph\textparagraph}{\textbardbl\textbardbl}} \setfnsymbol{safestar}   This comes  Achim Blumensath on the MinionPro mailing list, together with  for the footmisc package.  \documentclass[article, a4paper, 12pt, oneside]{memoir}  \usepackage{fontspec} \usepackage{xunicode} \usepackage{xltxtra} % c/o @wasteofspace, this is the "offending" line \defaultfontfeatures{Mapping=tex-text} \setmainfont{Linux Libertine O}  \usepackage[super]{natbib} \usepackage[perpage,symbol]{footmisc}  \let\sc\scshape \let\bf\bfseries \let\it\itfamily  \setlrmarginsandblock{23mm}{23mm}{*} \setulmarginsandblock{23mm}{198mm}{*} \checkandfixthelayout  \begin{document}  \bibliographystyle{plainnat} \setcitestyle{nature} \thispagestyle{empty}  This is a nice\footnote{(That is to say, minimal.)} example.\cite{lenat1976artificial,lenat1984and} Unfortunately, it has some problems.\footnote{From an aesthetic point of view.}  \bibliography{corneli}{}  \end{document}     But if we don't load , then we get this other slightly problematic result:   I guess I can live with the small and over-elevated asterisk.  It looks less bad when it follows a period. arccot limit: $\sum_{r=1}^{\infty}\cot ^{-1}(r^2+\frac{3}{4})$ I saw the sentence like     Donald Trump to run for president next month.   in the newspaper on the internet.  But I don't know why we have to use to instead of will.  Is there any rule I don't know?  Can anyone tell me the reason why we should use to in the news? How to rename multiple files sequentially from command line? How to rename file as below  AS1100801000002.RAW7AGS  AS1100801001008.RAW7AH4 AS1100801002001.RAW7AH9 AS1100801003002.RAW7AHE AS1100801004009.RAW7AHT AS1100801005002.RAW7AHY AS1100801010002.RAW7AJ3   to new name  AS1.txt AS2.txt AS3.txt AS4.txt AS5.txt AS6.txt AS7.txt My PDO Statement doesn't work I'll be traveling to Berlin, Germany from Colombo, Sri Lanka via Turkish Airways.  The itinerary would be: Colombo  &lt;--> Istanbul- || Istanbul- &lt;--> Berlin   The flights are all on one ticket. Would I be required to claim and re-check my baggage at Istanbul or can I check it in all the way from Colombo to Berlin without re-checking in the baggage again? $A \subseteq \mathcal{R}(N)$ and given that (by inductive definition):   $N ∈ S$. If $a \in R$, then $R \setminus \{a\} \in A$.    I need to prove that for each $A \in S$, $N\setminus A$ is finite. How can I prove this formally? Is CAT5 cable good enough for RS-485 vs "true" RS-485 cable Can I simplify an expression into form which uses my own definitions? I know that new arXiv papers usually appear in Google Scholar within a few days or weeks. My question is: if someone submits a replacement of his/her arXiv paper, does the new version of the paper also appear in Google Scholar? I have a CSV with an address field (no lat/long), so I went to Google My Maps, imported the csv and geocoded of the records.  Now I export the layer as KML and added the KML to QGIS and Google Earth Pro, but in non of them I can see the markers. In fact in QGIS, the KML layer is added as datatable (no geometry).  What's happening? How can I export a geometry layer from google My Maps? Is there an (easy) way to create or personalize .bst files? When you prepare an article for a journal (in my case, Quantum Information and Computation, Rinton Press), often they ask you to use some format for your references; in my case, the following:     [1] R. Calderbank and P. Shor (1996), Good quantum error          correcting codes exist,  Phys. Rev. A, 54, pp. 1098-1106.      [2] M.A. Nielsen and J. Kempe (2001), Separable states   are  more disordered globally than locally, quant-ph/0105090.      [3] A.W. Marshall and I. Olkin (1979), Inequalities:   theory of majorization and its applications, Academic Press (New   York).   The issue is, sometimes (and this is the case) they do not provide a .bst style file for bibtex users. I (and I guess many other people) prefer not to copy all the references of a bibtex file one by one into a tex document. So here is the question I am trying to answer:     What is the easiest way to create a .bst file? (for Rinton or any other publisher)   At first sight, I thought this would be very easy to do: after all, a .bst file is just a mere script to give format to a list. Strangely to me, after a long search I have been unable to find a simple clean solution to this problem. These are the the options I have been looking at:   I have tried to adapt a previous .bst file: concretely, apsrev4-1.bst, which has a similar format. Other people have tried this solution before , . However, it is an ugly option. First, it requires going through the script of the .bst and understanding it. Second, the script format used in different .bst files differs (quite annoyingly), so it is not easy to modify them unless you do understand what's written. The above solution is quite hideous and you really lose time on it, so I was wondering: isn't there any software tool (hopefully with a GUI) that does this job? It should, after all, pretty easy to program for a .bst script expert some sort of program to generate .bst files. There are some related questions in this site asking for something similar , ; there I have seen a couple of proposed apps, but going through their manuals they seem not so easy to use. Isn't there some software tool available to generate a .bst in less than 1 hour of work?   Remarks: ideally I would like to use/personalize/create .bst styles that support eprint fields (e.g. aps4-1.bst). How to fix apt: Signature by key uses weak digest algorithm (SHA1)? How to transform negative values to logarithms? I would like to know how to transform negative values to Log(), since I have heteroskedastic data. I read that it works with the formula Log(x+1) but this doesn't work with my database and I continue getting NaNs as result. E.g. I get this Warning message (I didn't put my complete database because I think with one of my negative values is enough to show an example):   &gt; log(-1.27+1) [1] NaN Warning message: In log(-1.27 + 1) : NaNs produced &gt;    Thanks in advance  UPDATE:  Here is an histogram of my data. I'm working with palaeontological time series of chemical measurements, E.g the difference between variables like Ca and Zn is too big, then I need some type of data standardization, that is why I'm testing the log() function.   This is my Navigation page buttons are orange everywhere On a similar note to this question:  (which only covers two examples only on the profile page, this question mentions more places on and outside the profile page where this bug occurs).  I've noticed that whenever there are these page buttons now, for example, the profile page, /questions and tag pages they are orange.  Per the other post I'm assuming this is a bug but if it was intentional then this is a feature request to make them theme-able per site again. Structuring game narrative. Handling NPC, Quest, General Dialogue. Is Json/XML the right way to go? Or any other solutions? Hello guys I'm try to make some games that have more to it than just simple high score scrolling shooters etc.  I'm trying to design my own systm of handling narrative. I want to be able to place NPC's in the game world, with scripts attached to them. Some of the NPC's would just have n random greetings. Others will be mission givers and will offer you a quest of sorts. (The quest could be go speak to Bob in the pub, or it might be bring me the Holy Grail and Crown Jewels, or something in between).  I've wracked my brain for a long while over this but sadly keep slipping back to the only way I know how, which is to manually code all the strings that people can say and have a horrible web of if statements and other such insanity to give me a rudimental dialogue system. Its not good enough even with just a few characters, but if I had dozens/hundreds of characters it would be even worse.  I've read lots about it already but I'm still very confused when I start trying on my own project. I've read that Json/XML might be the way to go and that I can add custom markups in the Json text to call methods in my code, but I dont even know if this is right and if so how I can do it.  The back of my brain is screaming at me that there is a simpler way to do it, but I've sat here for a very long time without managing to think of ideas.  Here is a diagram I drew which pretty much shows the flow of how I want my NPC to behave. If anyone can see this and then tell me how they might do something like this that would be fantastic!! (note: if Json is the correct advise, please give me a exact example of how exactly to format the Json in order to check the bools I mention in my flowchart - thanks!):    note: The circles denote an output from the data as Text for the dialogue system. The bools will need to be checked against by the data file to see which output to give (hope that makes sense and is possible) Make a computer act as a virtual USB device for other equipments In Ex Machina, can this character survive? Need to schedule a job every hour in jenkins I'm New to Jenkins. I have a job which i need to schedule every 1 hour.  I am using   * */1 * * *    but it is not working effectively.  Please provide any other solution.