<commit_before>.row
  .col-md-12
    %h1.page-header
      Edit assignment for #{@course.code}
    = form_for @assignment, :html => {:class => "form-horizontal"} do |f|
      %input{:name => "authenticity_token", :type => "hidden", :value => form_authenticity_token}
      .col-md-12
        %input{:name => "course_id", :type => "hidden", :value => @course.id}
        .row
          .col-md-8.col-md-offset-2
            %h3 Assignment details
            %label.control-label{:for => "assignment_name"} Assignment name
            .input-group
              .controls
                %input#assignment_name.form-control{:name => "assignment_name", :placeholder => "Assignment 1", :type => "text", :value => @assignment.name}
            %label.control-label{:for => "date_due"} Date Due
            .input-group
              .controls
                %input#date_due.form-control{:name => "date_due", :placeholder => "dd/mm/yyyy hh:mm, three hours from now, tomorrow 5pm...", :type => "text", :value => @assignment.due_date}
            .input-group
              = f.label :lang, "Language", class: "control-label"
              .controls
                = f.select :lang, Assignment::SUPPORTED_LANGUAGES, {}, class: "form-control"
              = f.label :kind, "Submission type"
              .controls
                = f.select :kind, Submission::SUPPORTED_TYPES, {}, class: "form-control", disabled: true
              .input-group
                - if @assignment.kind == "zip"
                  = f.label :zip_regex, "Files to ignore in ZIP submission preview"
                  .controls
                    = f.text_field :zip_regex, placeholder: "Example: \\.o|\\.png", class: "form-control"
                - else
                  = f.label :zip_regex, "Files to ignore in ZIP submission preview", class: "hidden"
                  .controls.hidden
                    = f.text_field :zip_regex, placeholder: "Example: \\.o|\\.png", class: "form-control"
              .controls
                = f.label :custom_compilation, "Use custom compilation", style: "padding: 0 !important"
                %span.small.light
                  (Options: $filename, $folder, $filepath)
                = f.check_box :custom_compilation
              - if @assignment.custom_compilation
                #custom-command-field.controls
                  = f.text_field :custom_command, class: "form-control", placeholder: "Enter a custom compilation command here"
              - else
                #custom-command-field.controls.hidden
                  = f.text_field :custom_command, class: "form-control", placeholder: "Enter a custom compilation command here"
            %label.control-label{:for => "text"} Submission instructions
            .input-group
              .controls
                %textarea#text.form-control{:name => "text", :rows => "8"}
                  = @assignment.description
            = if !@assignment.custom_command
              %label.control-label{:for => "tests"} Compilation tests (separate each boolean expression with a newline)
              .input-group
                .controls
                  %textarea#text.form-control{:name => "tests", :rows => "8"}
                    = @assignment.tests
            .input-group
              .controls
                = f.label :peer_review_enabled, "Enable peer review", style: "padding: 0 !important"
                - if @assignment.peer_review_enabled
                  = f.check_box :peer_review_enabled, checked: true
                - else
                  = f.check_box :peer_review_enabled
            .input-group
              .controls
                = f.label :disable_compilation, "Disable compilation", style: "padding: 0 !important"
                = f.check_box :disable_compilation, value: @assignment.disable_compilation
            .input-group
              .controls
                = f.label :pdf_regex, "Files to skip when making PDF", style: "padding: 0 !important"
                = f.text_field :pdf_regex, class: "form-control", placeholder: "Example: \\.o|\\.png"
            .input-group
              .controls
                %p
                  Also copy submission to:
                  %span.small.light
                    (Options: $uid, $fullname, $submissionid)
                = f.text_field :copy_path, class: "form-control", value: @assignment.copy_path
            .input-group
              .controls
                %input.btn.btn-primary{:style => "float:right;", :type => "submit", :value => "Save"}<commit_msg>Fix bug in assignment edit form<commit_after>.row
  .col-md-12
    %h1.page-header
      Edit assignment for #{@course.code}
    = form_for @assignment, :html => {:class => "form-horizontal"} do |f|
      %input{:name => "authenticity_token", :type => "hidden", :value => form_authenticity_token}
      .col-md-12
        %input{:name => "course_id", :type => "hidden", :value => @course.id}
        .row
          .col-md-8.col-md-offset-2
            %h3 Assignment details
            %label.control-label{:for => "assignment_name"} Assignment name
            .input-group
              .controls
                %input#assignment_name.form-control{:name => "assignment_name", :placeholder => "Assignment 1", :type => "text", :value => @assignment.name}
            %label.control-label{:for => "date_due"} Date Due
            .input-group
              .controls
                %input#date_due.form-control{:name => "date_due", :placeholder => "dd/mm/yyyy hh:mm, three hours from now, tomorrow 5pm...", :type => "text", :value => @assignment.due_date}
            .input-group
              = f.label :lang, "Language", class: "control-label"
              .controls
                = f.select :lang, Assignment::SUPPORTED_LANGUAGES, {}, class: "form-control"
              = f.label :kind, "Submission type"
              .controls
                = f.select :kind, Submission::SUPPORTED_TYPES, {}, class: "form-control", disabled: true
              .input-group
                - if @assignment.kind == "zip"
                  = f.label :zip_regex, "Files to ignore in ZIP submission preview"
                  .controls
                    = f.text_field :zip_regex, placeholder: "Example: \\.o|\\.png", class: "form-control"
                - else
                  = f.label :zip_regex, "Files to ignore in ZIP submission preview", class: "hidden"
                  .controls.hidden
                    = f.text_field :zip_regex, placeholder: "Example: \\.o|\\.png", class: "form-control"
              .controls
                = f.label :custom_compilation, "Use custom compilation", style: "padding: 0 !important"
                %span.small.light
                  (Options: $filename, $folder, $filepath)
                = f.check_box :custom_compilation
              - if @assignment.custom_compilation
                #custom-command-field.controls
                  = f.text_field :custom_command, class: "form-control", placeholder: "Enter a custom compilation command here"
              - else
                #custom-command-field.controls.hidden
                  = f.text_field :custom_command, class: "form-control", placeholder: "Enter a custom compilation command here"
            %label.control-label{:for => "text"} Submission instructions
            .input-group
              .controls
                %textarea#text.form-control{:name => "text", :rows => "8"}
                  = @assignment.description
            - if !@assignment.custom_command
              %label.control-label{:for => "tests"}
                Compilation tests (separate each boolean expression with a newline)
              .input-group
                .controls
                  %textarea#text.form-control{:name => "tests", :rows => "8"}
                    = @assignment.tests
            .input-group
              .controls
                = f.label :peer_review_enabled, "Enable peer review", style: "padding: 0 !important"
                - if @assignment.peer_review_enabled
                  = f.check_box :peer_review_enabled, checked: true
                - else
                  = f.check_box :peer_review_enabled
            .input-group
              .controls
                = f.label :disable_compilation, "Disable compilation", style: "padding: 0 !important"
                = f.check_box :disable_compilation, value: @assignment.disable_compilation
            .input-group
              .controls
                = f.label :pdf_regex, "Files to skip when making PDF", style: "padding: 0 !important"
                = f.text_field :pdf_regex, class: "form-control", placeholder: "Example: \\.o|\\.png"
            .input-group
              .controls
                %p
                  Also copy submission to:
                  %span.small.light
                    (Options: $uid, $fullname, $submissionid)
                = f.text_field :copy_path, class: "form-control", value: @assignment.copy_path
            .input-group
              .controls
                %input.btn.btn-primary{:style => "float:right;", :type => "submit", :value => "Save"}
{'fraction_non_alphanumeric': 0.1244259785698666, 'fraction_numerical': 0.0034987972884321017, 'mean_word_length': 1.7378030529781503, 'pattern_counts': {'":': 0, '<': 3, '<?xml version=': 0, '>': 57, 'https://': 0, 'lorem ipsum': 0, 'www.': 0, 'xml': 0}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 0, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'dir': 'git-commits-cleaned', 'id': '653436', 'n_tokens_mistral': 2537, 'n_tokens_neox': 2429, 'n_words': 582}