{"id":18383065,"url":"https://github.com/timkelty/shipit-assets","last_synced_at":"2025-04-06T23:32:04.452Z","repository":{"id":26600540,"uuid":"30055467","full_name":"timkelty/shipit-assets","owner":"timkelty","description":null,"archived":false,"fork":false,"pushed_at":"2020-07-15T19:40:43.000Z","size":17,"stargazers_count":16,"open_issues_count":6,"forks_count":3,"subscribers_count":1,"default_branch":"master","last_synced_at":"2025-03-19T07:42:03.538Z","etag":null,"topics":[],"latest_commit_sha":null,"homepage":null,"language":"JavaScript","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":null,"status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/timkelty.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":null,"code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null}},"created_at":"2015-01-30T04:03:14.000Z","updated_at":"2018-10-27T09:08:36.000Z","dependencies_parsed_at":"2022-08-17T17:30:50.667Z","dependency_job_id":null,"html_url":"https://github.com/timkelty/shipit-assets","commit_stats":null,"previous_names":[],"tags_count":10,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/timkelty%2Fshipit-assets","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/timkelty%2Fshipit-assets/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/timkelty%2Fshipit-assets/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/timkelty%2Fshipit-assets/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/timkelty","download_url":"https://codeload.github.com/timkelty/shipit-assets/tar.gz/refs/heads/master","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":247569124,"owners_count":20959758,"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-11-06T01:09:57.430Z","updated_at":"2025-04-06T23:32:02.865Z","avatar_url":"https://github.com/timkelty.png","language":"JavaScript","funding_links":[],"categories":[],"sub_categories":[],"readme":"# shipit-assets\n\nAsset syncing tasks for [Shipit](https://github.com/shipitjs/shipit).\n\n**Features:**\n\n- Works via [shipit-cli](https://github.com/shipitjs/shipit) and [grunt-shipit](https://github.com/shipitjs/grunt-shipit)\n\n## Install\n\n```\nnpm install shipit-assets\n```\n\n## Usage\n\n### Example `shipitfile.js`\n\n```js\nmodule.exports = function (shipit) {\n  require('shipit-assets')(shipit);\n\n  shipit.initConfig({\n    default: {\n      assets: {\n        paths: ['public/storage'],\n        options: {\n          ignores: ['cache']\n        },\n      }\n    },\n  });\n};\n```\n\nPush your local assets to remote:\n\n```\nshipit staging assets:push\n```\n\nPull your remote assets to local:\n\n```\nshipit staging assets:pull\n```\n\n### Example `Gruntfile.js`\n```js\ngrunt.initConfig({\n    shipit: {\n      options: {\n        workspace: '/tmp/github-monitor',\n        deployTo: '/tmp/deploy_to',\n        repositoryUrl: 'https://github.com/user/repo.git',\n        ignores: ['.git', 'node_modules'],\n        keepReleases: 2,\n        key: '/path/to/key',\n        shallowClone: true,\n        assets: {\n          'paths': [\n            'public/uploads',\n            'backup'\n          ]\n        },\n      },\n      staging: {\n        servers: 'user@myserver.com'\n      }\n    }\n  });\n\n  grunt.loadNpmTasks('grunt-shipit');\n  grunt.loadNpmTasks('shipit-deploy');\n  grunt.loadNpmTasks('shipit-assets');\n```\n\nTo run shipit-assets you have to call:\n`grunt shipit:staging assets:push`\n\n\n## Options (`shipit.config.assets`)\n\n### `assets.paths`\n\nType: `Array`\n\nPaths to sync between remote and local. Paths are relative to project root.\n\n### `assets.localPaths`\n\nType: `Array`\n\nIf your local paths are mapped differently than remote, you may specify here. If specified, the array must have the same length as `assets.paths`. Default: `assets.paths`\n\n### `assets.options`\n\nOptions to pass to [`shipit.remoteCopy`](https://github.com/shipitjs/shipit#shipitremotecopysrc-dest-options-callback).\n\n## Workflow tasks\n\n- assets:push\n  - Push assets from local to remote.\n  - Emit event \"assetsPush\".\n- assets:pull\n  - Pull assets from remote to local.\n  - Emit event \"assetsPull\".\n\n## License\n\nMIT\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Ftimkelty%2Fshipit-assets","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Ftimkelty%2Fshipit-assets","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Ftimkelty%2Fshipit-assets/lists"}