{"id":21344466,"url":"https://github.com/s00d/folder-upload-webpack-plugin","last_synced_at":"2025-03-16T03:21:42.653Z","repository":{"id":35146275,"uuid":"212803585","full_name":"s00d/folder-upload-webpack-plugin","owner":"s00d","description":null,"archived":false,"fork":false,"pushed_at":"2023-03-14T15:56:11.000Z","size":344,"stargazers_count":0,"open_issues_count":2,"forks_count":0,"subscribers_count":3,"default_branch":"master","last_synced_at":"2025-03-03T02:33:59.236Z","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/s00d.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":"2019-10-04T11:53:39.000Z","updated_at":"2022-06-23T04:35:46.000Z","dependencies_parsed_at":"2023-01-15T14:45:41.409Z","dependency_job_id":null,"html_url":"https://github.com/s00d/folder-upload-webpack-plugin","commit_stats":null,"previous_names":[],"tags_count":0,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/s00d%2Ffolder-upload-webpack-plugin","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/s00d%2Ffolder-upload-webpack-plugin/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/s00d%2Ffolder-upload-webpack-plugin/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/s00d%2Ffolder-upload-webpack-plugin/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/s00d","download_url":"https://codeload.github.com/s00d/folder-upload-webpack-plugin/tar.gz/refs/heads/master","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":243819312,"owners_count":20352868,"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-22T01:19:10.839Z","updated_at":"2025-03-16T03:21:42.624Z","avatar_url":"https://github.com/s00d.png","language":"JavaScript","funding_links":[],"categories":[],"sub_categories":[],"readme":"# folder-upload-webpack-plugin\n\u003e Upload your folder to ftp/sftp server easier and faster\n\n![](https://img.shields.io/npm/v/folder-upload-webpack-plugin.svg)\n[![NPM](https://nodei.co/npm/folder-upload-webpack-plugin.png)](https://nodei.co/npm/folder-upload-webpack-plugin/)\n\n## Installation\n```bash\nnpm i -D folder-upload-webpack-plugin\n```\n\n## Usage\nadd following code to your webpack config file.\n```javascript\nconst FolderUploadWebpackPlugin = require('folder-upload-webpack-plugin');\nlet webpackConfig = {\n  entry: 'index.js',\n  output: {\n    path: 'assets',\n    filename: 'index_bundle.js'\n  },\n  plugins: [\n    new FolderUploadWebpackPlugin({\n      confirmation: true,\n      server: {host: 'ip', port: '22', username: 'username', password: 'password'},\n      paths: () =\u003e {\n        let data = [];\n        data[path.resolve(__dirname, \"build_/\")] = path.join(\".../build/\");\n        return data;\n      },\n      clear: true,\n      logging: false,\n    })\n  ]\n}\n\n```\n### Options Detail:\n\nOption Name|Usage|Type|Default Value\n---|:--:|:--:|:-:\nconfirmation|show confirmation before upload|Boolean|false\nserver|ssh config for options(or Array, to multiple servers) you can see [docs](https://github.com/mscdex/ssh2#client-methods)|Object|{port:22}\npaths|function - return object {local: remote}, see path example|Function|(none)\nclear|optional clear server folder before upload|Boolean|true\nlogging|optional show log|Boolean|false\nsymlink|create local symlink, after upload|object|null\n\n### Extend Options Detail:\n\nOption Name|Usage|Type|Default Value\n---|:--:|:--:|:-:\nssh|optional ssh class|Class|see code\nchmod|optional compress level|Octal|0o644\nbefore|optional array with command|Array|[]\nafter|optional array with command|Array|[]\n\nfor other options you can see  https://github.com/mscdex/ssh2#client-methods\n\n## path example\n\n```\n... \npaths: () =\u003e {\n    let data = [];\n    data[path.resolve(__dirname, \"build_/\")] = path.join(\"...build/\");\n    return data;\n},...\n```\n\n## Change Log\n\n### 2.4.0\n```\n- fix ts\n```\n\n### 2.1.0\n```\n- add after and before command\n```\n\n### 2.0.0\n```\n- replace paths. see Options\n- remove pathsClear \u0026\u0026 remotePath\n```\n\n### 1.1.0\n```\n- change upload type\n```\n\n### 1.0.0\n```\n- init\n```\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fs00d%2Ffolder-upload-webpack-plugin","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fs00d%2Ffolder-upload-webpack-plugin","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fs00d%2Ffolder-upload-webpack-plugin/lists"}