{"id":16458302,"url":"https://github.com/flexbox/middleman-zip","last_synced_at":"2025-02-27T04:28:19.927Z","repository":{"id":26944130,"uuid":"30406792","full_name":"flexbox/middleman-zip","owner":"flexbox","description":"Middleman extension that zips directories.","archived":false,"fork":false,"pushed_at":"2015-02-06T10:18:34.000Z","size":111,"stargazers_count":0,"open_issues_count":0,"forks_count":0,"subscribers_count":3,"default_branch":"master","last_synced_at":"2025-01-10T03:19:07.925Z","etag":null,"topics":[],"latest_commit_sha":null,"homepage":null,"language":"Ruby","has_issues":false,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"mit","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/flexbox.png","metadata":{"files":{"readme":"README.md","changelog":"CHANGELOG.md","contributing":null,"funding":null,"license":"LICENSE","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null}},"created_at":"2015-02-06T10:16:59.000Z","updated_at":"2021-03-14T15:24:33.000Z","dependencies_parsed_at":"2022-06-26T11:03:38.928Z","dependency_job_id":null,"html_url":"https://github.com/flexbox/middleman-zip","commit_stats":null,"previous_names":[],"tags_count":2,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/flexbox%2Fmiddleman-zip","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/flexbox%2Fmiddleman-zip/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/flexbox%2Fmiddleman-zip/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/flexbox%2Fmiddleman-zip/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/flexbox","download_url":"https://codeload.github.com/flexbox/middleman-zip/tar.gz/refs/heads/master","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":240978195,"owners_count":19887834,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":[],"created_at":"2024-10-11T10:44:51.003Z","updated_at":"2025-02-27T04:28:19.903Z","avatar_url":"https://github.com/flexbox.png","language":"Ruby","readme":"# Middleman-Zip\n\n`middleman-zip` is an extension for the [Middleman](http://middlemanapp.com/) static site generator that allows you to zip directories.\n\n## Installation\n\nFirst, you need to have the `middleman` gem installed and a `middleman` project created. If you don't here's how:\n\n```\n$ gem install middleman\n$ middlman init my_project\n```\n\nAdd `gem 'middleman-zip'` to your project's `Gemfile` and run `bundle install`.\n\n## Configuration\n\nAdd the following to the `config.rb` of your Middleman project:\n\n```ruby\nactivate :zip, output_file: 'pkg/archive.zip'\n```\n\n### Options\n\n```ruby\n:input_dir    =\u003e 'build' # The directory that will be zipped.\n                         # String. Default: 'build' (or whatever you specified\n                         # as your build directory).\n\n:output_file  =\u003e nil     # Path to the final zip file.\n                         # String, has to end with '.zip'.\n                         # Required if :zip_map option is not set.\n\n:include_root =\u003e true    # Whether to include or not to include a root\n                         # directory. If a string is provided it will be used\n                         # as directory name.\n                         # Boolean (true/false) or string. Default: true.\n\n:moment       =\u003e :after  # Whether to zip files before or after build.\n                         # Symbol, possible values: :after, :before.\n                         # Default: :after\n\n:zip_map      =\u003e nil     # Array of hashed, each hash with optional :input_dir,\n                         # :include_root and :moment keys and required\n                         # :output_file key. See above for allowed values.\n                         # Array of hashed, Required if :output_file option\n                         # is not set.\n```\n\nExample with `:zip_map` option:\n\n```ruby\nactivate :zip, zip_map: [\n  { output_file: 'pkg/archive.zip' },\n  { input_dir: 'additional_files', output_file: 'pkg/additionals.zip' }\n]\n```\n\nOptions can be set in two ways:\n\n```ruby\nactivate :zip, output_file: 'pkg/build.zip'\n\n# or\n\nactivate :zip do |config|\n  config.output_file: 'pkg/build.zip'\nend\n```\n\n## Changelog\n\nSee [CHANGELOG.md](CHANGELOG.md).\n\n## License\n\nMIT. See [LICENSE](LICENSE).\n","funding_links":[],"categories":[],"sub_categories":[],"project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fflexbox%2Fmiddleman-zip","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fflexbox%2Fmiddleman-zip","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fflexbox%2Fmiddleman-zip/lists"}