Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Making custom slugs #19

Closed
volkanunsal opened this issue Apr 8, 2011 · 1 comment
Closed

Making custom slugs #19

volkanunsal opened this issue Apr 8, 2011 · 1 comment

Comments

@volkanunsal
Copy link

I'm trying to create a custom slug using the instructions in the slug.rb. Here is my attempt:

 slug :title do |doc|
   doc._id[0..5]+"/"+doc.title.sub(/\s+/,'-')
 end

But this doesn't seem to be working. Not even debugger is stopping the flow inside the block that is passed to it. Can you shed some light on what needs to be done here, and what I'm doing wrong. Thanks.

@digitalplaywright
Copy link
Collaborator

Please see issue #24 for how to do this.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants