forked from instructure/canvas-lms
-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
add frozen_string_literal comment to straggling lib files
mostly rake tasks Change-Id: Ia354de53f66b0707edac6db56a296c9005351922 Reviewed-on: https://gerrit.instructure.com/c/canvas-lms/+/261817 Tested-by: Service Cloud Jenkins <[email protected]> Reviewed-by: Rob Orton <[email protected]> QA-Review: Rob Orton <[email protected]> Product-Review: Rob Orton <[email protected]>
- Loading branch information
Showing
20 changed files
with
76 additions
and
36 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,3 +1,5 @@ | ||
# frozen_string_literal: true | ||
|
||
require 'rake/task_graph' | ||
require 'parallel' | ||
|
||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,3 +1,5 @@ | ||
# frozen_string_literal: true | ||
|
||
namespace :canvas do | ||
namespace :cdn do | ||
desc 'Push static assets to s3' | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,3 +1,5 @@ | ||
# frozen_string_literal: true | ||
|
||
namespace :css do | ||
desc "Generate styleguide" | ||
task :styleguide do | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,3 +1,5 @@ | ||
# frozen_string_literal: true | ||
|
||
namespace :db do | ||
desc "Create a new user" | ||
task :create_user => :environment do | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,3 +1,5 @@ | ||
# frozen_string_literal: true | ||
|
||
require 'securerandom' | ||
|
||
def ping | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,48 +1,51 @@ | ||
# frozen_string_literal: true | ||
|
||
begin | ||
require 'yard' | ||
require 'yard-appendix' | ||
require 'config/initializers/json' | ||
|
||
namespace :doc do | ||
DOC_DIR = File.join(%w[public doc api]) | ||
API_DOC_DIR = File.expand_path(Rails.root + DOC_DIR) | ||
DOC_OPTIONS = { | ||
# turning this on will show all the appendixes of all | ||
# controllers in the All Resources page | ||
:all_resource_appendixes => false | ||
} | ||
namespace :doc do | ||
DOC_DIR = File.join(%w[public doc api]) | ||
API_DOC_DIR = File.expand_path(Rails.root + DOC_DIR) | ||
DOC_OPTIONS = { | ||
# turning this on will show all the appendixes of all | ||
# controllers in the All Resources page | ||
:all_resource_appendixes => false | ||
}.freeze | ||
|
||
YARD::Tags::Library.define_tag("A Data Model", :model) | ||
YARD::Rake::YardocTask.new(:api) do |t| | ||
t.before = proc { FileUtils.rm_rf(API_DOC_DIR) } | ||
t.before = proc { `script/generate_lti_variable_substitution_markdown` } | ||
t.files = %w[ | ||
app/controllers/**/*.rb | ||
{gems,vendor}/plugins/*/app/controllers/*.rb | ||
{gems,vendor}/plugins/*/lib/*.rb | ||
] | ||
YARD::Tags::Library.define_tag("A Data Model", :model) | ||
YARD::Rake::YardocTask.new(:api) do |t| | ||
t.before = proc { FileUtils.rm_rf(API_DOC_DIR) } | ||
t.before = proc { `script/generate_lti_variable_substitution_markdown` } | ||
t.files = %w[ | ||
app/controllers/**/*.rb | ||
{gems,vendor}/plugins/*/app/controllers/*.rb | ||
{gems,vendor}/plugins/*/lib/*.rb | ||
] | ||
|
||
t.options = %W[ | ||
-e doc/api/api_routes.rb | ||
--title "Canvas REST API" | ||
-p doc | ||
-t api | ||
--readme doc/api/README.md | ||
-o #{API_DOC_DIR} | ||
--asset doc/images:images | ||
--asset doc/examples:examples | ||
] | ||
t.options = %W[ | ||
-e doc/api/api_routes.rb | ||
--title "Canvas REST API" | ||
-p doc | ||
-t api | ||
--readme doc/api/README.md | ||
-o #{API_DOC_DIR} | ||
--asset doc/images:images | ||
--asset doc/examples:examples | ||
] | ||
|
||
# t.options << '--verbose' | ||
# t.options << '--debug' | ||
end | ||
# t.options << '--verbose' | ||
# t.options << '--debug' | ||
end | ||
|
||
task 'api' do |t| | ||
puts "API Documentation successfully generated in #{DOC_DIR}\n" << | ||
"See #{DOC_DIR}/index.html" | ||
task 'api' do |t| | ||
puts "API Documentation successfully generated in #{DOC_DIR}\n" \ | ||
"See #{DOC_DIR}/index.html" | ||
end | ||
end | ||
end | ||
|
||
rescue LoadError | ||
# tasks not enabled | ||
nil | ||
end |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,3 +1,4 @@ | ||
# frozen_string_literal: true | ||
|
||
require "i18nliner/processors/abstract_processor" | ||
require "i18nliner/scope" | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,3 +1,5 @@ | ||
# frozen_string_literal: true | ||
|
||
require 'json' | ||
|
||
namespace :js do | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,3 +1,5 @@ | ||
# frozen_string_literal: true | ||
|
||
if Gem.loaded_specs.has_key?('pact') | ||
require 'pact/tasks' | ||
end |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters