Skip to content

Instantly share code, notes, and snippets.

@igniteflow
Last active April 18, 2018 14:01
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save igniteflow/1d846c8f61367b3a2741866fa4991229 to your computer and use it in GitHub Desktop.
Save igniteflow/1d846c8f61367b3a2741866fa4991229 to your computer and use it in GitHub Desktop.
Google Drive: fix dotfile renaming

Google Drive replaces the leading dot in dot-filenames with an underscore. To undo this after downloading the files as a zip run

  # replaces leading underscores with dots
  rename -n 's/^_/./g' *  # first check
  rename 's/^_/./g' *  # now execute

After downloading the files be sure to set the correct permissions

chmod 700 ~/.ssh
chmod 644 ~/.ssh/*.pub
# update private files to 600
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment