Skip to content

Instantly share code, notes, and snippets.

@bvjebin
Created August 31, 2018 13:48
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 bvjebin/07b16752235d2f155638df1579a028b8 to your computer and use it in GitHub Desktop.
Save bvjebin/07b16752235d2f155638df1579a028b8 to your computer and use it in GitHub Desktop.
Create zip in elixir for medium post
def create_zip(path) do
old_path = File.cwd!
File.cd! path
:zip.create("images.zip", ['images'], [{:cwd, path}])
File.cd! old_path
path<>"/images.zip"
end
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment