Custom rake tasks

I created a .rake file for my custom rake tasks under /lib/tasks/
But these tasks were not available via command line. I have to add this line to load these tasks

# Rakefile

Dir.glob('lib/tasks/*.rake').each { |r| import r }

If this is helpful, would like to add this via PR so all jets new automatically gets custom rake tasks imported.
Let me know if there is a better way.
If this is good to add, any pointers on what file I can look to modify for PR?

Weird the generated Rakefile that jets new creates should already have a Jets.load_tasks method in it that should load the tasks.

It eventually leads to this:

Which should load the tasks. Unsure if import or load make a difference. Will have to test.

PR created:

I am having the same issue with custom rake files not being loaded/recognized in Jets 1.9.30.

@ratneshraval’s fix did the trick.

Interesting when I tested it, it was the exact opposite. Wondering if it has to do with rake versions :thinking:

I had that problem but I verified and in latest version it works as expected. There is no need to import them if you’re on the latest version 2.0.4. Not sure when it was fixed but I removed my import line.