Our rake tasks are currently using the
... rake notes:custom # Enumerate a custom annotation, specify with ANNOTATION=CUSTOM rake openfoodnetwork:billing:finalize_account_invoices # Finalize enterprise user invoices rake openfoodnetwork:billing:update_account_invoices # Update enterprise user invoices rake openfoodnetwork:cache:check_products_integrity # check the integrity of the products cache rake openfoodnetwork:cache:warm_products # warm the products cache rake openfoodnetwork:data:create_order_cycle_relationships # Adding relationships based on recent order cycles rake openfoodnetwork:dev:export_enterprises # export enterprises to CSV rake openfoodnetwork:dev:load_sample_data # load sample data rake paperclip:clean # Cleans out invalid attachments ...
- It is redundant.
- It is inefficient to type.
I was just about to agree with him when I thought about one benefit of having our own namespace:
rake -Tlists tasks by namespace and groups our tasks together.
We have 93 tasks in 31 namespaces. Some come from Rails and others from our gems. If we wouldn’t use a namespace, we wouldn’t see which tasks are ours.
Now I would like to discuss two options:
- Change our rake namespace to
ls lib/tasks/instead of