Posts about computers

Enable/disable spotlight in OSX

24 January 2015

This is just a self reminder on how to disable and enable spotlight in Snow Leopard and Lion. Open a terminal and type: To enable:

sudo mdutil -a -i on To disable: sudo mdutil -a -i off In system preferences you can control which drives and/or folders are not to be indexed.

Nice tweaks for OSX

24 January 2015

I think most of them work on both Snow Leopard and Lion. Not sure about previous versions. Just type the ones you want to activate/deactivate on the command line and have fun. # Enable full keyboard access for all controls (e.g. enable Tab in modal dialogs) defaults write NSGlobalDomain AppleKeyboardUIMode -int 3

# Enable the 2D Dock defaults write com.apple.dock no-glass -bool true

# Disable menu bar transparency defaults write -g AppleEnableMenuBarTransparency -bool false

# Expand save p...

NonUniqueObjectException- a different object with the same identifier value was already associated with the session

24 January 2015

If you are developing in Swing and using hibernate you might - at some point in time - run into this exception: org.hibernate.NonUniqueObjectException: a different object with the same identifier value was already associated with the session

What happened, you might ask? Well, turns out that when you close the session that created a given hibernate-managed object, this object becomes "detached" (meaning hibernate no longer has any control over it). So, when you attempt to save or update it in ...

Displaying posts 10 - 12 of 94 in total