How to get admin access to Tomcat 7 on OS X Yosemite

In continuing the path to learn more about Tomcat 7, I had to configured my local instance to give me admin access to the “Server Status,” “Manager App,” and “Host Manager” pages.  It was actually quiet easy.

    1. In your terminal, go to /usr/local/Cellar/tomcat7/7.0.63/libexec/conf
    2. vim tomcat-users.xml
    3. Add the following:

    
      <role rolename="manager-gui"/>
      <role rolename="admin-gui"/>
      <user username="tomcat" password="s3cret" roles="manager-gui,admin-gui"/>
    

IntelliJ IDEA: Pass M2_HOME to the IDE on OS X Yosemite

I had issues in Yosemite with IntelliJ always complaining that it couldn’t see my M2_HOME variable, even though I had it in my .bash_profile.  Turns out that only works in the terminal.

In any case, this worked — I verified it on my Mac, which runs v10.10.5.

1. Save this plist in ~/Library/LaunchAgents/ as custom.startup.plist



Label
my.startup
ProgramArguments

sh
-c
launchctl setenv VARIABLE_NAME1 VARIABLE_VALUE1 | launchctl setenv VARIABLE_NAME2 VARIABLE_VALUE2 | launchctl setenv VARIABLE_NAME3 VARIABLE_VALUE3

RunAtLoad
2. Log out then back in

3. That's it!

Importing Apple Notes into Evernote

Just copy and paste the following into the Script Editor and viola!

tell application "Notes"
set theMessages to every note
repeat with thisMessage in theMessages
set myTitle to the name of thisMessage
set myText to the body of thisMessage
set myCreateDate to the creation date of thisMessage
set myModDate to the modification date of thisMessage
tell application "Evernote"
set myNote to create note with text myTitle title myTitle notebook "Imported Notes" tags ["imported_from_notes", "TODO"]
set the HTML content of myNote to myText
set the creation date of myNote to myCreateDate
set the modification date of myNote to myCreateDate
end tell
end repeat
end tell

Source: Importing Apple Notes into EverNote | jeremyrnelson