Re-program the Arduino Uno without losing a base (custom firmware) sketch

Is it that hard to make your functionality a library and hide the internals from the user? If you want users to be able to interact with it without revealing teh source code, you can always ofuscate it.