#33 ✓resolved
Matt Todd

Configurable Load Paths

Reported by Matt Todd | April 29th, 2008 @ 11:07 PM | in Release 0.5.0

The hardcoded paths inside of Halcyon for file locations such as configuration, initialization, libraries, tests (for the future), controllers, etc.

These are the default locations:

  • controllers: app/
  • configuration: config/
  • initialization: config/initialize
  • libs: lib/

With this implemented, it can be trivial to expand functionality to include logging locations (aside from fully expanded locations in the configuration file) etc, but more importantly, to change locations without the internals ever knowing.

Here are some suggested changes/additions to the default paths:

  • controllers: app/controllers/
  • models: app/models/
  • configuration: config/
  • initialization: config/init
  • logs: not set, could be log/
  • libs: lib/
  • public files: public/
  • specs: spec/
  • tasks: tasks/

Some clarifications for the above suggested list: models just provides the developer a place to put them, not necessarily indicating that Halcyon will support specific ORMs; logs could be moved to be local to the application, and deployment can have them put in /var/log/... instead; specs are preferred (by me) but other types of testing is certainly acceptable; public files would include a simple HTML file and JavaScript or CSS files for special circumstances, like pure AJAX apps (for example, see the Guesser sample app); and tasks would simply be a place for predefined Rake tasks, making the primary Rakefile a great place for custom tasks and not have to dodge the already-existing tasks.

One related property could be load order which would be necessary for making sure that the requires are loaded before hooks (though it shouldn't really be a problem in the end, the way hooks are run).

Comments and changes to this ticket

Please Sign in or create a free account to add a new ticket.

With your very own profile, you can contribute to projects, track your activity, watch tickets, receive and update tickets through your email and much more.

New-ticket Create new ticket

Create your profile

Help contribute to this project by taking a few moments to create your personal profile. Create your profile »

People watching this ticket

Pages