<commit_before>#!/bin/bash

aws iam list-users --query "Users[].[UserName]" --output text | while read User; do
  SaveUserName="$User"
  SaveUserName=${SaveUserName//"+"/".plus."}
  SaveUserName=${SaveUserName//"="/".equal."}
  SaveUserName=${SaveUserName//","/".comma."}
  SaveUserName=${SaveUserName//"@"/".at."}
  if id -u "$SaveUserName" >/dev/null 2>&1; then
    echo "$SaveUserName exists"
  else
    #sudo will read each file in /etc/sudoers.d, skipping file names that end in ‘~’ or contain a ‘.’ character to avoid causing problems with package manager or editor temporary/backup files.
    SaveUserFileName=$(echo "$SaveUserName" | tr "." " ")
    /usr/sbin/adduser "$SaveUserName"
    echo "$SaveUserName ALL=(ALL) NOPASSWD:ALL" > "/etc/sudoers.d/$SaveUserFileName"
  fi
done<commit_msg>Disabling sudo access by default. Ref : Issue #11<commit_after>#!/bin/bash

aws iam list-users --query "Users[].[UserName]" --output text | while read User; do
  SaveUserName="$User"
  SaveUserName=${SaveUserName//"+"/".plus."}
  SaveUserName=${SaveUserName//"="/".equal."}
  SaveUserName=${SaveUserName//","/".comma."}
  SaveUserName=${SaveUserName//"@"/".at."}
  if id -u "$SaveUserName" >/dev/null 2>&1; then
    echo "$SaveUserName exists"
  else
    /usr/sbin/adduser "$SaveUserName"

    # sudo will read each file in /etc/sudoers.d,
    # skipping file names that end in ‘~’ or contain a ‘.’ character
    # to avoid causing problems with package manager or editor temporary/backup files.
    # Uncomment the following lines if you need to give all users sudo privileges

    # SaveUserFileName=$(echo "$SaveUserName" | tr "." " ")
    # echo "$SaveUserName ALL=(ALL) NOPASSWD:ALL" > "/etc/sudoers.d/$SaveUserFileName"
  fi
done
{'fraction_non_alphanumeric': 0.1673398730525101, 'fraction_numerical': 0.003462204270051933, 'mean_word_length': 3.857142857142857, 'pattern_counts': {'":': 0, '<': 3, '<?xml version=': 0, '>': 9, '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': '4690199', 'n_tokens_mistral': 587, 'n_tokens_neox': 558, 'n_words': 155}