Dru Jensen

Results 75 comments of Dru Jensen

@watzon Amber's CLI has all of the functionality you mentioned and uses Granite. `amber db drop create migrate seed` and `amber generate model Post title:string body:text published:bool` are the commands...

@watzon I researched this a little more and the Amber CLI has some dependencies that make it a little difficult to use in stand-alone mode. We might be able to...

I see. Unfortunately, the Migrator concept you described will not work in a real production environment. I built this in Granite about three years ago. It would automatically look at...

Not yet. You are looking for `includes` or eager loading. See ticket #65 Your best option is to query each of these tables separately. Not sure how to get those...

I was with you until I read your conclusion. The assumption that you need a DSL to support OOP and ActiveRecord design pattern is questionable but... I am in agreement...

@eliasjpr Thanks for the clarification. I agree with your comment regarding Active Record and it's one reason we should be careful not to head down the slippery slope of trying...

Thanks for you quick response! Here is my controller: https://github.com/drujensen/crystal-blog/blob/master/app/controllers/post_controller.cr When I inspect the @callback_methods, it doesn't have any of the @actions I list. It has the @types instead. Not...

I have a fix but I'm not happy with it. Basically, to register the `action` in the macro, you need the list of actions that the before filter applies too....

I verified that the `only:` option works. The `before_action :authorized?` doesn't work. Specifically: ``` crystal macro before_action(callback, only=[] of Symbol) {% if only.empty? %} {% only = @type.methods.map(&.name.stringify) %} {%...

Thanks @Sdogruyol . How do I get the list of actions in the other macro called `before_action`? Can one macro use the results of another?