<commit_before># Usage: copy <file>

function copy --description "Copy the contents of a text file or variable to your clipboard"
  set --local argc (count $argv)
  if test $argc -eq 1
    switch (uname)
      case 'Linux'
        if test -e $argv[1]
          xclip -selection clip < $argv[1]
        else
          echo $argv[1] | xclip -selection clip
        end
      case 'Darwin'
        if test -e $argv[1]
          pbcopy < $argv[1]
        else
          echo $argv[1] | pbcopy
        end
    end
  else
    echo "Well this is embarrassing... I can only copy one file at a time."
  end
end
<commit_msg>:bug: Do not add a newline to copied variables<commit_after># Usage: copy <file>

function copy --description "Copy the contents of a text file or variable to your clipboard"
  set --local argc (count $argv)
  if test $argc -eq 1
    switch (uname)
      case 'Linux'
        if test -e $argv[1]
          xclip -selection clip < $argv[1]
        else
          printf $argv[1] | xclip -selection clip
        end
      case 'Darwin'
        if test -e $argv[1]
          pbcopy < $argv[1]
        else
          printf $argv[1] | pbcopy
        end
    end
  else
    echo "Well this is embarrassing... I can only copy one file at a time."
  end
end

{'fraction_non_alphanumeric': 0.09011857707509881, 'fraction_numerical': 0.011067193675889328, 'mean_word_length': 1.857787810383747, 'pattern_counts': {'":': 0, '<': 9, '<?xml version=': 0, '>': 5, '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': '5774555', 'n_tokens_mistral': 399, 'n_tokens_neox': 392, 'n_words': 166}