Skip to content

Commit

Permalink
Run perltidy on the code with the new version.
Browse files Browse the repository at this point in the history
  • Loading branch information
drgrice1 committed Nov 21, 2024
1 parent 779f313 commit 993440d
Show file tree
Hide file tree
Showing 94 changed files with 200 additions and 203 deletions.
2 changes: 1 addition & 1 deletion bin/crypt_passwords_in_classlist.pl
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,7 @@ BEGIN

use lib "$ENV{WEBWORK_ROOT}/lib";

use WeBWorK::Utils qw(cryptPassword);
use WeBWorK::Utils qw(cryptPassword);
use WeBWorK::File::Classlist qw(parse_classlist write_classlist);

unless (@ARGV == 1) {
Expand Down
4 changes: 2 additions & 2 deletions bin/dev_scripts/PODtoHTML.pm
Original file line number Diff line number Diff line change
Expand Up @@ -23,8 +23,8 @@ use Pod::Simple::Search;
use Mojo::Template;
use Mojo::DOM;
use Mojo::Collection qw(c);
use File::Path qw(make_path);
use File::Basename qw(dirname);
use File::Path qw(make_path);
use File::Basename qw(dirname);
use IO::File;
use POSIX qw(strftime);

Expand Down
4 changes: 2 additions & 2 deletions bin/dev_scripts/generate-ww-pg-pod.pl
Original file line number Diff line number Diff line change
Expand Up @@ -65,9 +65,9 @@ =head1 DESCRIPTION
use Mojo::Template;
use IO::File;
use File::Copy;
use File::Path qw(make_path remove_tree);
use File::Path qw(make_path remove_tree);
use File::Basename qw(dirname);
use Cwd qw(abs_path);
use Cwd qw(abs_path);

use lib dirname(dirname(dirname(__FILE__))) . '/lib';
use lib dirname(__FILE__);
Expand Down
2 changes: 1 addition & 1 deletion bin/download-OPL-metadata-release.pl
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,7 @@

BEGIN {
use Mojo::File qw(curfile);
use Env qw(WEBWORK_ROOT);
use Env qw(WEBWORK_ROOT);

$WEBWORK_ROOT = curfile->dirname->dirname;
}
Expand Down
2 changes: 1 addition & 1 deletion bin/dump-OPL-tables.pl
Original file line number Diff line number Diff line change
Expand Up @@ -22,7 +22,7 @@

BEGIN {
use Mojo::File qw(curfile);
use Env qw(WEBWORK_ROOT);
use Env qw(WEBWORK_ROOT);

$WEBWORK_ROOT = curfile->dirname->dirname;
}
Expand Down
2 changes: 1 addition & 1 deletion bin/dump-past-answers.pl
Original file line number Diff line number Diff line change
Expand Up @@ -98,7 +98,7 @@ =head1 DESCRIPTION

BEGIN {
use Mojo::File qw(curfile);
use Env qw(WEBWORK_ROOT);
use Env qw(WEBWORK_ROOT);
$WEBWORK_ROOT = curfile->dirname->dirname;
}

Expand Down
2 changes: 1 addition & 1 deletion bin/generate-OPL-set-def-lists.pl
Original file line number Diff line number Diff line change
Expand Up @@ -26,7 +26,7 @@ =head1 DESCRIPTION

BEGIN {
use Mojo::File qw(curfile);
use Env qw(WEBWORK_ROOT);
use Env qw(WEBWORK_ROOT);

$WEBWORK_ROOT = curfile->dirname->dirname;
}
Expand Down
4 changes: 2 additions & 2 deletions bin/importClassList.pl
Original file line number Diff line number Diff line change
Expand Up @@ -19,7 +19,7 @@

BEGIN {
use Mojo::File qw(curfile);
use Env qw(WEBWORK_ROOT);
use Env qw(WEBWORK_ROOT);

$WEBWORK_ROOT = curfile->dirname->dirname;
}
Expand All @@ -31,7 +31,7 @@ BEGIN

use WeBWorK::DB qw(check_user_id);
use WeBWorK::File::Classlist;
use WeBWorK::Utils qw(cryptPassword);
use WeBWorK::Utils qw(cryptPassword);
use WeBWorK::File::Classlist qw(parse_classlist);

if ((scalar(@ARGV) != 2)) {
Expand Down
2 changes: 1 addition & 1 deletion bin/load-OPL-global-statistics.pl
Original file line number Diff line number Diff line change
Expand Up @@ -21,7 +21,7 @@

BEGIN {
use Mojo::File qw(curfile);
use Env qw(WEBWORK_ROOT);
use Env qw(WEBWORK_ROOT);

$WEBWORK_ROOT = curfile->dirname->dirname;
}
Expand Down
2 changes: 1 addition & 1 deletion bin/restore-OPL-tables.pl
Original file line number Diff line number Diff line change
Expand Up @@ -22,7 +22,7 @@

BEGIN {
use Mojo::File qw(curfile);
use Env qw(WEBWORK_ROOT);
use Env qw(WEBWORK_ROOT);

$WEBWORK_ROOT = curfile->dirname->dirname;
}
Expand Down
2 changes: 1 addition & 1 deletion bin/test_library_build.pl
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@

BEGIN {
use Mojo::File qw(curfile);
use Env qw(WEBWORK_ROOT);
use Env qw(WEBWORK_ROOT);

$WEBWORK_ROOT = curfile->dirname->dirname;
}
Expand Down
2 changes: 1 addition & 1 deletion bin/update-OPL-statistics.pl
Original file line number Diff line number Diff line change
Expand Up @@ -19,7 +19,7 @@

BEGIN {
use Mojo::File qw(curfile);
use Env qw(WEBWORK_ROOT);
use Env qw(WEBWORK_ROOT);

$WEBWORK_ROOT = curfile->dirname->dirname;
}
Expand Down
2 changes: 1 addition & 1 deletion bin/updateOPLextras.pl
Original file line number Diff line number Diff line change
Expand Up @@ -71,7 +71,7 @@ =head1 DESCRIPTION

BEGIN {
use Mojo::File qw(curfile);
use Env qw(WEBWORK_ROOT);
use Env qw(WEBWORK_ROOT);

$WEBWORK_ROOT = curfile->dirname->dirname;
}
Expand Down
2 changes: 1 addition & 1 deletion bin/upgrade-database-to-utf8mb4.pl
Original file line number Diff line number Diff line change
Expand Up @@ -126,7 +126,7 @@ =head1 OPTIONS

BEGIN {
use Mojo::File qw(curfile);
use Env qw(WEBWORK_ROOT);
use Env qw(WEBWORK_ROOT);

$WEBWORK_ROOT = curfile->dirname->dirname;
}
Expand Down
2 changes: 1 addition & 1 deletion bin/upgrade_admin_db.pl
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,7 @@

BEGIN {
use Mojo::File qw(curfile);
use Env qw(WEBWORK_ROOT);
use Env qw(WEBWORK_ROOT);

$WEBWORK_ROOT = curfile->dirname->dirname;
}
Expand Down
2 changes: 1 addition & 1 deletion bin/upload-OPL-statistics.pl
Original file line number Diff line number Diff line change
Expand Up @@ -19,7 +19,7 @@

BEGIN {
use Mojo::File qw(curfile);
use Env qw(WEBWORK_ROOT);
use Env qw(WEBWORK_ROOT);

$WEBWORK_ROOT = curfile->dirname->dirname;
}
Expand Down
4 changes: 2 additions & 2 deletions lib/FormatRenderedProblem.pm
Original file line number Diff line number Diff line change
Expand Up @@ -26,10 +26,10 @@ use warnings;

use JSON;
use Digest::SHA qw(sha1_base64);
use Mojo::Util qw(xml_escape);
use Mojo::Util qw(xml_escape);
use Mojo::DOM;

use WeBWorK::Utils qw(getAssetURL);
use WeBWorK::Utils qw(getAssetURL);
use WeBWorK::Utils::LanguageAndDirection qw(get_lang_and_dir get_problem_lang_and_dir);

sub formatRenderedProblem {
Expand Down
5 changes: 2 additions & 3 deletions lib/HardcopyRenderedProblem.pm
Original file line number Diff line number Diff line change
Expand Up @@ -29,7 +29,7 @@ use warnings;
use File::Path;
use String::ShellQuote;
use Archive::Zip qw(:ERROR_CODES);
use Mojo::File qw(path tempdir);
use Mojo::File qw(path tempdir);
use XML::LibXML;

sub hardcopyRenderedProblem {
Expand Down Expand Up @@ -265,8 +265,7 @@ sub write_problem_tex {
$correctTeX .=
"\\item\n\$\\displaystyle "
. ($rh_result->{answers}{$_}{correct_ans_latex_string}
|| "\\text{$rh_result->{answers}{$_}{correct_ans}}")
. "\$\n";
|| "\\text{$rh_result->{answers}{$_}{correct_ans}}") . "\$\n";
}

$correctTeX .= "\\end{itemize}}\\par\n";
Expand Down
2 changes: 1 addition & 1 deletion lib/Mojolicious/WeBWorK.pm
Original file line number Diff line number Diff line change
Expand Up @@ -28,7 +28,7 @@ use Mojo::JSON qw(encode_json);

use WeBWorK;
use WeBWorK::CourseEnvironment;
use WeBWorK::Utils::Logs qw(writeTimingLogEntry);
use WeBWorK::Utils::Logs qw(writeTimingLogEntry);
use WeBWorK::Utils::Routes qw(setup_content_generator_routes);

sub startup ($app) {
Expand Down
2 changes: 1 addition & 1 deletion lib/WeBWorK/AchievementEvaluator.pm
Original file line number Diff line number Diff line change
Expand Up @@ -24,7 +24,7 @@ use Mojo::Base 'Exporter', -signatures;

use DateTime;

use WeBWorK::Utils qw(sortAchievements nfreeze_base64 thaw_base64);
use WeBWorK::Utils qw(sortAchievements nfreeze_base64 thaw_base64);
use WeBWorK::Utils::ProblemProcessing qw(compute_unreduced_score);
use WeBWorK::Utils::Tags;
use WeBWorK::WWSafe;
Expand Down
4 changes: 2 additions & 2 deletions lib/WeBWorK/AchievementItems/AddNewTestGW.pm
Original file line number Diff line number Diff line change
Expand Up @@ -18,9 +18,9 @@ use Mojo::Base 'WeBWorK::AchievementItems', -signatures;

# Item to allow students to take an additional version of a test within its test version interval

use WeBWorK::Utils qw(x nfreeze_base64 thaw_base64);
use WeBWorK::Utils qw(x nfreeze_base64 thaw_base64);
use WeBWorK::Utils::DateTime qw(before between);
use WeBWorK::Utils::Sets qw(format_set_name_display);
use WeBWorK::Utils::Sets qw(format_set_name_display);

sub new ($class) {
return bless {
Expand Down
4 changes: 2 additions & 2 deletions lib/WeBWorK/AchievementItems/DoubleProb.pm
Original file line number Diff line number Diff line change
Expand Up @@ -20,9 +20,9 @@ use Mojo::Base 'WeBWorK::AchievementItems', -signatures;

use Mojo::JSON qw(encode_json);

use WeBWorK::Utils qw(x nfreeze_base64 thaw_base64);
use WeBWorK::Utils qw(x nfreeze_base64 thaw_base64);
use WeBWorK::Utils::DateTime qw(after);
use WeBWorK::Utils::Sets qw(format_set_name_display);
use WeBWorK::Utils::Sets qw(format_set_name_display);

sub new ($class) {
return bless {
Expand Down
4 changes: 2 additions & 2 deletions lib/WeBWorK/AchievementItems/DoubleSet.pm
Original file line number Diff line number Diff line change
Expand Up @@ -18,9 +18,9 @@ use Mojo::Base 'WeBWorK::AchievementItems', -signatures;

# Item to make a homework set worth twice as much

use WeBWorK::Utils qw(x nfreeze_base64 thaw_base64);
use WeBWorK::Utils qw(x nfreeze_base64 thaw_base64);
use WeBWorK::Utils::DateTime qw(after);
use WeBWorK::Utils::Sets qw(format_set_name_display);
use WeBWorK::Utils::Sets qw(format_set_name_display);

sub new ($class) {
return bless {
Expand Down
4 changes: 2 additions & 2 deletions lib/WeBWorK/AchievementItems/DuplicateProb.pm
Original file line number Diff line number Diff line change
Expand Up @@ -20,9 +20,9 @@ use Mojo::Base 'WeBWorK::AchievementItems', -signatures;

use Mojo::JSON qw(encode_json);

use WeBWorK::Utils qw(x nfreeze_base64 thaw_base64);
use WeBWorK::Utils qw(x nfreeze_base64 thaw_base64);
use WeBWorK::Utils::DateTime qw(between);
use WeBWorK::Utils::Sets qw(format_set_name_display);
use WeBWorK::Utils::Sets qw(format_set_name_display);

sub new ($class) {
return bless {
Expand Down
4 changes: 2 additions & 2 deletions lib/WeBWorK/AchievementItems/ExtendDueDate.pm
Original file line number Diff line number Diff line change
Expand Up @@ -18,9 +18,9 @@ use Mojo::Base 'WeBWorK::AchievementItems', -signatures;

# Item to extend a close date by 24 hours.

use WeBWorK::Utils qw(x nfreeze_base64 thaw_base64);
use WeBWorK::Utils qw(x nfreeze_base64 thaw_base64);
use WeBWorK::Utils::DateTime qw(between);
use WeBWorK::Utils::Sets qw(format_set_name_display);
use WeBWorK::Utils::Sets qw(format_set_name_display);

sub new ($class) {
return bless {
Expand Down
4 changes: 2 additions & 2 deletions lib/WeBWorK/AchievementItems/ExtendDueDateGW.pm
Original file line number Diff line number Diff line change
Expand Up @@ -18,9 +18,9 @@ use Mojo::Base 'WeBWorK::AchievementItems', -signatures;

# Item to extend the close date on a test

use WeBWorK::Utils qw(x nfreeze_base64 thaw_base64);
use WeBWorK::Utils qw(x nfreeze_base64 thaw_base64);
use WeBWorK::Utils::DateTime qw(between);
use WeBWorK::Utils::Sets qw(format_set_name_display);
use WeBWorK::Utils::Sets qw(format_set_name_display);

sub new ($class) {
return bless {
Expand Down
4 changes: 2 additions & 2 deletions lib/WeBWorK/AchievementItems/FullCreditProb.pm
Original file line number Diff line number Diff line change
Expand Up @@ -20,9 +20,9 @@ use Mojo::Base 'WeBWorK::AchievementItems', -signatures;

use Mojo::JSON qw(encode_json);

use WeBWorK::Utils qw(x nfreeze_base64 thaw_base64);
use WeBWorK::Utils qw(x nfreeze_base64 thaw_base64);
use WeBWorK::Utils::DateTime qw(after);
use WeBWorK::Utils::Sets qw(format_set_name_display);
use WeBWorK::Utils::Sets qw(format_set_name_display);

sub new ($class) {
return bless {
Expand Down
4 changes: 2 additions & 2 deletions lib/WeBWorK/AchievementItems/FullCreditSet.pm
Original file line number Diff line number Diff line change
Expand Up @@ -18,9 +18,9 @@ use Mojo::Base 'WeBWorK::AchievementItems', -signatures;

# Item to give half credit on all problems in a homework set.

use WeBWorK::Utils qw(x nfreeze_base64 thaw_base64);
use WeBWorK::Utils qw(x nfreeze_base64 thaw_base64);
use WeBWorK::Utils::DateTime qw(after);
use WeBWorK::Utils::Sets qw(format_set_name_display);
use WeBWorK::Utils::Sets qw(format_set_name_display);

sub new ($class) {
return bless {
Expand Down
4 changes: 2 additions & 2 deletions lib/WeBWorK/AchievementItems/HalfCreditProb.pm
Original file line number Diff line number Diff line change
Expand Up @@ -20,9 +20,9 @@ use Mojo::Base 'WeBWorK::AchievementItems', -signatures;

use Mojo::JSON qw(encode_json);

use WeBWorK::Utils qw(x nfreeze_base64 thaw_base64);
use WeBWorK::Utils qw(x nfreeze_base64 thaw_base64);
use WeBWorK::Utils::DateTime qw(after);
use WeBWorK::Utils::Sets qw(format_set_name_display);
use WeBWorK::Utils::Sets qw(format_set_name_display);

sub new ($class) {
return bless {
Expand Down
4 changes: 2 additions & 2 deletions lib/WeBWorK/AchievementItems/HalfCreditSet.pm
Original file line number Diff line number Diff line change
Expand Up @@ -18,9 +18,9 @@ use Mojo::Base 'WeBWorK::AchievementItems', -signatures;

# Item to give half credit on all problems in a homework set.

use WeBWorK::Utils qw(x nfreeze_base64 thaw_base64);
use WeBWorK::Utils qw(x nfreeze_base64 thaw_base64);
use WeBWorK::Utils::DateTime qw(after);
use WeBWorK::Utils::Sets qw(format_set_name_display);
use WeBWorK::Utils::Sets qw(format_set_name_display);

sub new ($class) {
return bless {
Expand Down
4 changes: 2 additions & 2 deletions lib/WeBWorK/AchievementItems/ReducedCred.pm
Original file line number Diff line number Diff line change
Expand Up @@ -19,9 +19,9 @@ use Mojo::Base 'WeBWorK::AchievementItems', -signatures;
# Item to extend a close date by 24 hours for reduced credit
# Reduced scoring needs to be enabled for this item to work.

use WeBWorK::Utils qw(x nfreeze_base64 thaw_base64);
use WeBWorK::Utils qw(x nfreeze_base64 thaw_base64);
use WeBWorK::Utils::DateTime qw(between);
use WeBWorK::Utils::Sets qw(format_set_name_display);
use WeBWorK::Utils::Sets qw(format_set_name_display);

sub new ($class) {
return bless {
Expand Down
4 changes: 2 additions & 2 deletions lib/WeBWorK/AchievementItems/ResetIncorrectAttempts.pm
Original file line number Diff line number Diff line change
Expand Up @@ -20,9 +20,9 @@ use Mojo::Base 'WeBWorK::AchievementItems', -signatures;

use Mojo::JSON qw(encode_json);

use WeBWorK::Utils qw(x nfreeze_base64 thaw_base64);
use WeBWorK::Utils qw(x nfreeze_base64 thaw_base64);
use WeBWorK::Utils::DateTime qw(between);
use WeBWorK::Utils::Sets qw(format_set_name_display);
use WeBWorK::Utils::Sets qw(format_set_name_display);

sub new ($class) {
return bless {
Expand Down
4 changes: 2 additions & 2 deletions lib/WeBWorK/AchievementItems/ResurrectGW.pm
Original file line number Diff line number Diff line change
Expand Up @@ -18,9 +18,9 @@ use Mojo::Base 'WeBWorK::AchievementItems', -signatures;

# Item to extend the due date on a gateway

use WeBWorK::Utils qw(x nfreeze_base64 thaw_base64);
use WeBWorK::Utils qw(x nfreeze_base64 thaw_base64);
use WeBWorK::Utils::DateTime qw(after);
use WeBWorK::Utils::Sets qw(format_set_name_display);
use WeBWorK::Utils::Sets qw(format_set_name_display);

sub new ($class) {
return bless {
Expand Down
4 changes: 2 additions & 2 deletions lib/WeBWorK/AchievementItems/ResurrectHW.pm
Original file line number Diff line number Diff line change
Expand Up @@ -18,9 +18,9 @@ use Mojo::Base 'WeBWorK::AchievementItems', -signatures;

# Item to resurrect a homework for 24 hours

use WeBWorK::Utils qw(x nfreeze_base64 thaw_base64);
use WeBWorK::Utils qw(x nfreeze_base64 thaw_base64);
use WeBWorK::Utils::DateTime qw(after);
use WeBWorK::Utils::Sets qw(format_set_name_display);
use WeBWorK::Utils::Sets qw(format_set_name_display);

sub new ($class) {
return bless {
Expand Down
4 changes: 2 additions & 2 deletions lib/WeBWorK/AchievementItems/SuperExtendDueDate.pm
Original file line number Diff line number Diff line change
Expand Up @@ -18,9 +18,9 @@ use Mojo::Base 'WeBWorK::AchievementItems', -signatures;

# Item to extend a close date by 48 hours.

use WeBWorK::Utils qw(x nfreeze_base64 thaw_base64);
use WeBWorK::Utils qw(x nfreeze_base64 thaw_base64);
use WeBWorK::Utils::DateTime qw(between);
use WeBWorK::Utils::Sets qw(format_set_name_display);
use WeBWorK::Utils::Sets qw(format_set_name_display);

sub new ($class) {
return bless {
Expand Down
Loading

0 comments on commit 993440d

Please sign in to comment.