title: Bash: chmod +x localizable.sh : Permission denied
body: <p>I am running a <code>.sh</code> script and it runs fine locally (<code>sh /Users/Me/Documents/development/MyRepo/localizable.sh</code>).</p>
  <p>However, when I add it to Github actions, I get permission denied.</p>
  <p>Exact error:</p>
  <pre><code>Run chmod +x localizable.sh 
    chmod +x localizable.sh 
    export LOCALIZATION_OUTPUT=$(bash ./localizable.sh) 
    export LOCALIZATION_OUTPUT=&quot;${LOCALIZATION_OUTPUT//'%'/'%25'}&quot; 
    export LOCALIZATION_OUTPUT=&quot;${LOCALIZATION_OUTPUT//$'n'/'%0A'}&quot; 
    export LOCALIZATION_OUTPUT=&quot;${LOCALIZATION_OUTPUT//$'&lt;NL&gt;'/'%0A'}&quot; 
    export LOCALIZATION_OUTPUT=&quot;${LOCALIZATION_OUTPUT//$''/'%0A'}&quot; 
    export LOCALIZATION_OUTPUT=&quot;${LOCALIZATION_OUTPUT//$'\r'/'%0D'}&quot; 
    echo $(cat output.txt) 
    echo &quot;::set-output name=message::$LOCALIZATION_OUTPUT&quot;
    shell: /bin/bash -e {0}
  ./localizable.sh: line 38: MyProject/Localizations/en.lproj/Localizable.strings: Permission denied
  grep: Unmatched ( or \(
  grep: Unmatched ( or \(
  ./localizable.sh: line 50: done: command not found
  ./localizable.sh: line 38: MyProject/Localizations/en.lproj/Localizable.strings: Permission denied
  grep: Unmatched ( or \(
  </code></pre>
  <p>This is what .sh file looks like:</p>
  <pre><code>#!/bin/sh
  if [[ -z $lang ]]
      then
      lang=&quot;en&quot;
  fi
  searchDir=&quot;MyProject/Localizations/$lang.lproj&quot;
  echo &quot;*Verifying NSLocalizationStrings in &quot;$searchDir&quot;*&quot;
  output=$(grep -R  NSLocalizedString . --include=&quot;*.swift&quot;)
  count=$(( 0 ))
  missing=$(( 0 ))
  unusable=$(( 0 ))
  OIFS=&quot;${IFS}&quot;
  NIFS=$'\n'
  IFS=&quot;${NIFS}&quot;
  echo &quot;Entering Loop ${output}&quot;
  for LINE in ${output} ; do
      echo &quot;loop entered&quot;
      IFS=&quot;${OIFS}&quot;
      quotes=`echo $LINE | awk -F\&quot; '{ for(i=2; i&lt;=NF; i=i+2){ a = a&quot;\\&quot;&quot;$i&quot;\\&quot;&quot;&quot;^&quot;;} {print a; a=&quot;&quot;;}}'`
      key=`echo $quotes | cut -f1 -d&quot;^&quot;`
      # 1. Issues with extracting keys if \[\[ -z $key \]\]
      if [[ -z $key ]]
      then
          (( unusable += 1 ))
      echo &quot;Couldn't extract key: &quot; $LINE
      fi
      keyLength=$(echo ${#key})
      
      # 2. Issues with keys that are too long
      if [ $keyLength -gt 79 ]
      then
          (( unusable += 1 ))
      echo &quot;Key too long (&quot;$keyLength&quot;): &quot; $key
      fi
      keyString=$key&quot; =&quot;
      found=$(iconv -sc -f UTF-16 -t UTF-8
  &quot;$searchDir/Localizable.strings&quot; | grep &quot;$keyString&quot;)
          if [[ -z $found ]]
          then
          found=$(grep -r &quot;$keyString&quot; &quot;$searchDir&quot;/ --include=*.strings)
          fi
          if [[ -z $found ]]
          then
              (( missing += 1 )) 
          echo &quot;&lt;NL&gt;**Missing**: \`$key\` from: 
          &lt;NL&gt;\`\`\`swift&lt;NIL&gt;$LINE&lt;NL&gt;\`\`\`&quot; 
          fi 
          (( count += 1 )) 
          
          IFS=&quot;${NIFS}&quot; done IFS=&quot;${OIFS}&quot;
  done
  IFS=&quot;${OIFS}&quot; 
  echo &quot;&lt;NL&gt;Out of $count keys: &lt;NL&gt;- $unusable not determined&lt;NL&gt;- $missing missing&quot; 
  if [[ $missing &gt; 0 ]] 
  then 
      echo &quot;::set-output name=keys_missing::true&quot; &gt;&gt; output.txt 
  else echo &quot;::set-output name=keys_missing::false&quot; &gt;&gt; output.txt 
  fi
  </code></pre>
  <p>How can I get this to run on Github, or anywhere else besides my computer?</p>