{"id":13397962,"url":"https://github.com/stojanovic/scottyjs","last_synced_at":"2025-03-14T00:32:51.493Z","repository":{"id":90350789,"uuid":"99826556","full_name":"stojanovic/scottyjs","owner":"stojanovic","description":"Deploy static websites and single page apps to AWS S3 and CloudFront with a single command","archived":true,"fork":false,"pushed_at":"2021-07-16T14:19:19.000Z","size":6602,"stargazers_count":705,"open_issues_count":12,"forks_count":37,"subscribers_count":12,"default_branch":"master","last_synced_at":"2024-08-30T18:51:08.849Z","etag":null,"topics":["aws-s3","deployment","static-site"],"latest_commit_sha":null,"homepage":"http://medium.com/@slobodan/single-command-deployment-for-single-page-apps-29941d62ef97","language":"JavaScript","has_issues":true,"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/stojanovic.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":"LICENSE","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null}},"created_at":"2017-08-09T15:54:30.000Z","updated_at":"2024-08-08T13:27:59.000Z","dependencies_parsed_at":"2023-06-10T15:45:19.269Z","dependency_job_id":null,"html_url":"https://github.com/stojanovic/scottyjs","commit_stats":{"total_commits":74,"total_committers":11,"mean_commits":"6.7272727272727275","dds":"0.32432432432432434","last_synced_commit":"b1c8ef73cf6da8776a7bcf3602a9702beacc4321"},"previous_names":[],"tags_count":13,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/stojanovic%2Fscottyjs","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/stojanovic%2Fscottyjs/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/stojanovic%2Fscottyjs/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/stojanovic%2Fscottyjs/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/stojanovic","download_url":"https://codeload.github.com/stojanovic/scottyjs/tar.gz/refs/heads/master","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":243505150,"owners_count":20301559,"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":["aws-s3","deployment","static-site"],"created_at":"2024-07-30T18:01:57.889Z","updated_at":"2025-03-14T00:32:50.698Z","avatar_url":"https://github.com/stojanovic.png","language":"JavaScript","funding_links":[],"categories":["JavaScript"],"sub_categories":[],"readme":"# Scotty.js\n\nAs you probably noticed, Scotty.js is not active anymore. Working on Scotty.js was fun, but AWS released AWS Amplify in the meantime, and tools such as Scotty.js are no longer needed. Please take a look at the [AWS Amplify Console](https://aws.amazon.com/amplify/hosting/). It's an excellent tool for hosting static websites and single-page applications.\n\n---\n\nDeploy static websites or folders to AWS S3 with a single command\n\n\u003ch1 align=\"center\"\u003e\n  \u003cimg width=\"400\" src=\"https://raw.githubusercontent.com/stojanovic/scottyjs/master/scotty-header.png\" alt=\"scotty header\"\u003e\n  \u003cbr/\u003e\n\u003c/hr\u003e\n\n[![Build Status](https://travis-ci.org/stojanovic/scottyjs.svg?branch=master)](https://travis-ci.org/stojanovic/scottyjs)\n[![npm](https://img.shields.io/npm/v/scottyjs.svg?maxAge=2592000?style=plastic)](https://www.npmjs.com/package/scottyjs)\n[![npm](https://img.shields.io/npm/dt/scottyjs.svg?maxAge=2592000?style=plastic)](https://www.npmjs.com/package/scottyjs)\n[![npm](https://img.shields.io/npm/l/scottyjs.svg?maxAge=2592000?style=plastic)](https://github.com/stojanovic/scottyjs/blob/master/LICENSE)\n[![Join the chat at https://gitter.im/scottyjs/scotty](https://badges.gitter.im/scottyjs/scotty.svg)](https://gitter.im/scottyjs/scotty?utm_source=badge\u0026utm_medium=badge\u0026utm_campaign=pr-badge\u0026utm_content=badge)\n\n## Install\n\nScotty.js is available on NPM. Install it as a global dependency to be able to use `scotty` command anywhere:\n\n```shell\nnpm install scottyjs --global\n```\n\n## Use\n\n\u003e Beam me up, Scotty\n\n![](scotty-intro.gif)\n\nTo deploy a static folder to AWS S3 run:\n\n ```shell\nscotty {options}\n ```\n\nor\n\n```shell\nbeam-me-up {options}\n```\n\n### Available options\n\n- _--help_ or _-h_ - Print this help\n- _--version_ or _-v_ - Print the current version\n- _--noclipboard_ or _-n_ - Do not copy the URL to clipboard (default: false)\n- _--quiet_ or _-q_ - Suppress output when executing commands (default: false)\n- _--website_ or _-w_ - Set uploaded folder as a static website (default: false)\n- _--spa_ - Set uploaded folder as a single page app (default: false)\n- _--source_  or _-s_ - Source of the folder that will be uploaded (default: current folder)\n- _--bucket_ or _-b_ - Name of the S3 bucket (default: name of the current folder)\n- _--prefix_ or _-p_ - Prefix on the S3 bucket (default: the root of the bucket)\n- _--region_ or _-r_ - AWS region where the files will be uploaded, default: saved region if exists or a list to choose one if it is not saved yet\n- _--force_ or _-f_ - Update the bucket without asking (default: false, forced region can be overridden with _-r_)\n- _--update_ or _-u_ - Update existing bucket (default: false)\n- _--delete_ or _-d_ - Delete existing bucket (default: false)\n- _--nocdn_ or _-c_ - Disable Cloudfront handling (default: false)\n- _--urlonly_ or _-o_ - Only output the resulting URL, CDN or S3 according to options (default: false)\n- _--expire_ or _-e_ - delete objects on bucket older than n days (default: no expiration)\n- _--profile_ or _-a_ - AWS profile to be used (default: 'default')\n- _--empty_ or _-y_ - Empty the bucket (Delete all objects before upload files) (default: false)\n\n### Examples\n\n#### _Create React App_ application\n\nFull tutorial: http://medium.com/@slobodan/single-command-deployment-for-single-page-apps-29941d62ef97\n\nTo deploy [CRA](https://github.com/facebookincubator/create-react-app) apps simply run `npm run build` in your project root folder to create build version.\n\nThen deploy build version using following command:\n\n```shell\nscotty --spa --source ./build\n```\n\nOr, if you want to specify bucket name run:\n\n```shell\nscotty --spa --source ./build --bucket some-bucket-name\n```\n\nWith `--spa` flag, Scotty will set required redirects for your single page app, so your app can use pushState out of the box.\n\n#### _Shared bucket_ application\n\nTo deploy multiple apps to a single bucket you can make use of the `--prefix`\noption. This comes in handy when your CI system deploys to a staging system\nwith each branch as a pathname. Eg. the `master` branch should go to bucket\nroot (`/`), so you do not set the prefix. The `feature/fancy-stuff` branch\nshould go to the bucket path `feature/fancy-stuff` so just add this as the\nprefix. Here comes a command line example:\n\n```shell\n# deploy your master branch build to bucket root\nscotty --source ./build --bucket some-bucket-name\n# deploy your branch build to the branch name on the bucket\nscotty --source_ ./build --bucket some-bucket-name --prefix your/branch\n```\n\n## Test\n\nWe use [Jasmine](https://jasmine.github.io/) for unit and integration tests. Unless there is a very compelling reason to use something different, please continue using Jasmine for tests. The existing tests are in the [spec](spec) folder. Here are some useful command shortcuts:\n\nRun all the tests:\n\n```bash\nnpm test\n```\n\nRun only some tests:\n\n```bash\nnpm test -- filter=prefix\n```\n\nGet detailed hierarchical test name reporting:\n\n```bash\nnpm test -- full\n```\n## License\n\nMIT -- see [LICENSE](LICENSE)\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fstojanovic%2Fscottyjs","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fstojanovic%2Fscottyjs","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fstojanovic%2Fscottyjs/lists"}