Skip to content

Commit

Permalink
Re-added rake task to save to a file the aterm script to create a pro…
Browse files Browse the repository at this point in the history
…ject (#860)
  • Loading branch information
hectorcorrea authored Jul 25, 2024
1 parent ef2823b commit f5375cd
Showing 1 changed file with 10 additions and 0 deletions.
10 changes: 10 additions & 0 deletions lib/tasks/projects.rake
Original file line number Diff line number Diff line change
Expand Up @@ -81,6 +81,16 @@ namespace :projects do
puts service.aterm_script
end

desc "Outputs to a file the Aterm script to create a project in Mediaflux"
task :create_script_file, [:project_id] => [:environment] do |_, args|
project_id = args[:project_id]
project = Project.find(project_id)
service = MediafluxScriptFactory.new(project: project)
file_name = "project_create_#{project.id}.txt"
puts "Saving script to #{file_name}"
File.write(file_name, service.aterm_script)
end

task :download_file_list, [:netid, :project_id] => [:environment] do |_, args|
netid = args[:netid]
user = User.where(uid: netid).first
Expand Down

0 comments on commit f5375cd

Please sign in to comment.