I'm running Ubuntu, with Gnome3 as my desktop manager. While debugging some initialization issues (the usual confusion over bash_profile, bashrc, etc.), I found that given the following files,  # ~/.bash_profile export X=x  # ~/.profile export Y=y   if I reboot, log in, and start a shell, it seems like ~/.bash_profile was never sourced:  $ echo ${X-var_not_set} var_not_set $ echo ${Y-var_not_set} y   I'm using Gnome terminal, running non-login shells (the default), so it makes sense that ~/.bash_profile would not be sourced when I start a shell in the terminal emulator, but I thought ~/.bash_profile would have been sourced when I originally logged in at the graphical login screen.  I'm unclear whether that login screen is the domain of the OS (Ubuntu), the graphical shell (Gnome), or something else (display manager?), and thus, what initialization files are run.  The Bash manual says that ~/.bash_profile will be used instead of ~/.profile if it's present, but the above behavior seems to contradict that.     When bash is invoked as an interactive login shell, or as  a  non-interactive  shell with  the  --login  option,  it  ...  looks  for ~/.bash_profile,  ~/.bash_login,  and  ~/.profile, in that order, and reads and executes commands from the first one that exists  and  is  readable.   My best guess is that the graphical login has nothing to do with Bash (is this related to dash shell?), and as such, it executes ~/.profile. Is that the case, or is there more to this that I'm misunderstanding?
I'm using Linux Mint. My login shell (cat /etc/passwd | grep myUserName) is bash.  After I start my graphical desktop environment and run a terminal emulator from it, I can see that .bash_profile is not sourced (environment vars that are exported in it are unset). But if I log in from a text console (ctrl+alt+F1) or manually run bash -l from the terminal emulator, .bash_profile works fine.  Am I wrong when I think that .bash_profile should be sourced when X starts and all export'ed vars should be available in the terminal, running from X?  P.S. Placing everything in .bashrc and sourcing it from .bash_profile is not good idea (): environment stuff should be sourced only once.
How can I respawn the Ender Dragon? I have a server and the Ender dragon has been defeated.  However, returning to The End does not respawn the Ender Dragon.  How can I get the final boss back on a vanilla server without using mods? Is it safe to use file's hash as IV? I'm encrypting some files using AES in CBC mode.    I'm also using file's digest (SHA-1) to check that data is decrypted correctly (so I need to store it with file).  Is it safe to use this digest as AES's IV and store it in the header of file? Or it has security issue? What good CAD programs are available? Best way to add KeyEvents and faster Quit Why is.vector on a data-frame doesn't return TRUE? I'm adding a title clock in the foot line of a beamer slide, if I compile it with pdfLaTeX it works fine; while the clock doesn't align in the middle vertically if compiling with XeLaTeX. How can I fix this.  Here is my MWE:  \documentclass[10pt]{beamer} \usepackage[font=Times,timeinterval=1]{tdclock} \usetheme{Madrid} \title{Title} \author{Authors} \institute{Institute} \date[\initclock\tddate\ \ \tdtime]{\today} \begin{document} \frame{\titlepage} \end{document} How does quantum trapping with diamagnets work? I just saw  demonstration by someone from a Tel Aviv University lab.  What they achieved there is mind blowing. I myself own a levitron that uses the Hall effect to levitate a magnet, the problem with that is the magnet must always be flat facing the Hall effect base, any unbalance will wreck the levitation. But in the case of the video you can see that he isn't constrained by such things, the disk can levitate and stay still at whatever angle and orientation. Instead of being levitated, the disk is simply being held still.   How does this happen? He referred to this as quantum trapping, but I've little idea about what that is....  Also, what material is the base in these demos? Is the circular track in the demonstration magnetic? I assume this is so. Is there any conceivable way for this technology to make objects levitate on any surface? Is it possible to search every field of every table for a particular value in Oracle?  There are hundreds of tables with thousands of rows in some tables so I know this could take a very long time to query. But the only thing I know is that a value for the field I would like to query against is 1/22/2008P09RR8. &lt;  I've tried using this statement below to find an appropriate column based on what I think it should be named but it returned no results.  SELECT * from dba_objects  WHERE object_name like '%DTN%'   There is absolutely no documentation on this database and I have no idea where this field is being pulled from.  Any thoughts? Occasionally (very occasionally) when returning to the main page of a site by clicking on the logo I get the following message:     It was not possible to perform this tag search at this time due to an unexpected error.   This is odd because I'm not performing a tag search.  So far this has happened on both Movies &amp; TV and Cooking.  I have heard that others are getting this same message. How do I derive the Lorentz contraction from the invariant interval? Reviewing some basic special relativity, and I stumbled upon this problem:  From the definition of the proper time: $$c^2d\tau^2=c^2dt^2-dx^2$$ I was able to derive the time dilation formula by using $x=vt$: $$c^2d\tau^2=c^2dt^2-v^2dt^2=c^2dt^2\left(1-\frac{v^2}{c^2}\right)\rightarrow d\tau = dt\sqrt{1-\frac{v^2}{c^2}}=t/\gamma$$  Now, I would very much like to be able to derive the length contraction formula in a similar fashion, and feel strongly that this should be possible. The definition of the invariant interval is: $$ds^2=dx^2-c^2dt^2$$ using $t=\frac{x}{v}$ I tried: $$ds^2=dx^2-\frac{c^2}{v^2}dx^2=dx^2\left(1-\frac{c^2}{v^2}\right)\rightarrow ds=dx\sqrt{1-\frac{c^2}{v^2}}$$  This is where I'm stuck: I don't see how this can be converted to a Lorentz factor...  Any help that will allow me to arrive at the desired result $ds=\gamma dx$ would be very much appreciated. At the start of Harry Potter and the Philosopher's/Sorceror's Stone Voldemort's Killing Curse backfires      due to Lily's sacrifice protecting Harry from Voldemort.   leaving Harry with his scar      and a loose piece of Voldemort's soul   and Voldemort as a loose soul, self-described as "Less than a ghost".  Voldemort was not dead, but had no physical body (until he got better in book 4).  What happened to his body?  Did it disappear?  Or was it left in the rubble of the house, alongside the bodies of James and Lily? I am trying to understand how complex numbers made their way into QM. Can we have a theory of the same physics without complex numbers? If so, is the theory using complex numbers easier? I am trying to ask a question on SE, have some mock data in Excel I've copied, and am simply trying to paste in to my question.  I've done this before dozens of times, but suddenly am having this issue.  However, when I do so, I get prompted to upload an image. (This happens with Ctrl + V and also right click --> Paste):    Am I overlooking something?  Edit: Playing around, I can copy from Firefox/browsers and Word, and paste in to the box as usual. Excel seems to be the only one giving the issue so far.  Edit2:  are still having this issue. ASP.NET MVC: Weird characters in error page Are these solutions of $2 = x^{x^{x^{\:\cdot^{\:\cdot^{\:\cdot}}}}}$ correct? If that's not possible, then a way to trigger the Dock on the screen with mouse without moving my cursor to the bottom of the screen is also an acceptable solution (I know that the launchpad appears on the screen with Dock)  Also i did see the  about this. Have a seat, guys   I think "have a seat" is a fixed phrase that does not change whether you address someone or a group of people.  Is that correct?  If you have more to add to the post, please do so as I would love to know more. Why does a mirror split my laser beam? Why is a subgroup with the index of 2 normal to the group?  I believe it has something to do with it being half and having nowhere to go. I have searched, but not found anything on this. I am looking for a functionality in bash, using a terminal.  Way back when, I had a user on a debian system, and a friend set me up with a convenient history search feature (I believe I used tcsh then), where I would type the beginning of a previous command, hit up-arrow, and it would do a search, based on the partial string.  E.g. if my history is:  ./script.pl ./script.pl arg1 cat output cat output | grep yada   And I type ., and press up-arrow, it would show me: ./script.pl arg1. Press it again and it would show ./script.pl, etc.  Very much like it would perform a grep on .bash_history. Is there a way to get this functionality?