diff --git a/.github/workflows/deploy.yml b/.github/workflows/deploy.yml new file mode 100644 index 00000000..a3069083 --- /dev/null +++ b/.github/workflows/deploy.yml @@ -0,0 +1,21 @@ +name: Upload Website + +on: + push: + branches: + - master + +jobs: + deploy: + runs-on: ubuntu-latest + steps: + - uses: actions/checkout@master + - uses: jakejarvis/s3-sync-action@master + with: + args: --acl public-read --follow-symlinks --delete + env: + AWS_S3_BUCKET: ${{ secrets.AWS_S3_BUCKET }} + AWS_ACCESS_KEY_ID: ${{ secrets.AWS_ACCESS_KEY_ID }} + AWS_SECRET_ACCESS_KEY: ${{ secrets.AWS_SECRET_ACCESS_KEY }} + AWS_REGION: 'us-west-1' # optional: defaults to us-east-1 + SOURCE_DIR: 'public' # optional: defaults to entire repository \ No newline at end of file diff --git a/LICENSE b/LICENSE deleted file mode 100644 index 7cf19bc5..00000000 --- a/LICENSE +++ /dev/null @@ -1,7 +0,0 @@ -Copyright © Patrick Gillespie, http://patorjk.com - -Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated documentation files (the "Software"), to deal in the Software without restriction, including without limitation the rights to use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of the Software, and to permit persons to whom the Software is furnished to do so, subject to the following conditions: - -The above copyright notice and this permission notice shall be included in all copies or substantial portions of the Software. - -THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. \ No newline at end of file diff --git a/README.md b/README.md deleted file mode 100755 index f2181309..00000000 --- a/README.md +++ /dev/null @@ -1,19 +0,0 @@ -JavaScript Snake
-By Patrick Gillespie
-License: MIT
-http://patorjk.com/games/snake - -This is a DOM-based game of Snake that I wrote in JavaScript a few years back. - -Other than the full screen mode demonstrated in the code, it can also be -initialized in div tags within a page. Example: - - var mySnakeBoard = new SNAKE.Board( { - boardContainer: "game-area", - fullScreen: false, - width: 580, - height:400 - }); - -The comments are formatted a little strange because at the time I was playing -around with YUI Doc. diff --git a/package.json b/package.json deleted file mode 100644 index 381a117a..00000000 --- a/package.json +++ /dev/null @@ -1,23 +0,0 @@ -{ - "name": "javascript-snake", - "version": "1.0.0", - "description": "JavaScript Snake
By Patrick Gillespie
License: MIT
http://patorjk.com/games/snake", - "main": "js/snake.js", - "scripts": { - "test": "echo \"Error: no test specified\" && exit 1" - }, - "repository": { - "type": "git", - "url": "git+https://github.com/patorjk/JavaScript-Snake.git" - }, - "author": "", - "license": "MIT", - "bugs": { - "url": "https://github.com/patorjk/JavaScript-Snake/issues" - }, - "homepage": "https://github.com/patorjk/JavaScript-Snake#readme", - "devDependencies": { - "webpack": "^4.41.1", - "webpack-cli": "^3.3.9" - } -} diff --git a/css/dark-snake.css b/public/css/dark-snake.css similarity index 100% rename from css/dark-snake.css rename to public/css/dark-snake.css diff --git a/css/green-snake.css b/public/css/green-snake.css similarity index 100% rename from css/green-snake.css rename to public/css/green-snake.css diff --git a/css/images/Thumbs.db b/public/css/images/Thumbs.db old mode 100755 new mode 100644 similarity index 100% rename from css/images/Thumbs.db rename to public/css/images/Thumbs.db diff --git a/css/images/dark-snakeblock.png b/public/css/images/dark-snakeblock.png similarity index 100% rename from css/images/dark-snakeblock.png rename to public/css/images/dark-snakeblock.png diff --git a/css/images/dead-dark-snakeblock.png b/public/css/images/dead-dark-snakeblock.png similarity index 100% rename from css/images/dead-dark-snakeblock.png rename to public/css/images/dead-dark-snakeblock.png diff --git a/css/images/deadblock.png b/public/css/images/deadblock.png old mode 100755 new mode 100644 similarity index 100% rename from css/images/deadblock.png rename to public/css/images/deadblock.png diff --git a/css/images/deadblock_border.png b/public/css/images/deadblock_border.png similarity index 100% rename from css/images/deadblock_border.png rename to public/css/images/deadblock_border.png diff --git a/css/images/favicon.png b/public/css/images/favicon.png similarity index 100% rename from css/images/favicon.png rename to public/css/images/favicon.png diff --git a/css/images/matrix-food-block.png b/public/css/images/matrix-food-block.png similarity index 100% rename from css/images/matrix-food-block.png rename to public/css/images/matrix-food-block.png diff --git a/css/images/matrix-snake-block.png b/public/css/images/matrix-snake-block.png similarity index 100% rename from css/images/matrix-snake-block.png rename to public/css/images/matrix-snake-block.png diff --git a/css/images/snakeblock.png b/public/css/images/snakeblock.png old mode 100755 new mode 100644 similarity index 100% rename from css/images/snakeblock.png rename to public/css/images/snakeblock.png diff --git a/css/light-snake.css b/public/css/light-snake.css similarity index 100% rename from css/light-snake.css rename to public/css/light-snake.css diff --git a/css/main-snake.css b/public/css/main-snake.css old mode 100755 new mode 100644 similarity index 100% rename from css/main-snake.css rename to public/css/main-snake.css diff --git a/css/matrix-snake.css b/public/css/matrix-snake.css similarity index 100% rename from css/matrix-snake.css rename to public/css/matrix-snake.css diff --git a/index.html b/public/index.html old mode 100755 new mode 100644 similarity index 68% rename from index.html rename to public/index.html index 1f68cdf0..92efea5a --- a/index.html +++ b/public/index.html @@ -3,11 +3,8 @@ @@ -69,36 +66,6 @@ -
-
- Theme: - -
-
- Mode: - -
-
-
- -
diff --git a/js/min-snake.js b/public/js/min-snake.js similarity index 100% rename from js/min-snake.js rename to public/js/min-snake.js diff --git a/js/snake.js b/public/js/snake.js similarity index 99% rename from js/snake.js rename to public/js/snake.js index 02b6653f..244cf966 100644 --- a/js/snake.js +++ b/public/js/snake.js @@ -672,7 +672,7 @@ SNAKE.Board = SNAKE.Board || (function() { elmAboutPanel = document.createElement("div"); elmAboutPanel.className = "snake-panel-component"; - elmAboutPanel.innerHTML = "more patorjk.com apps - source code - pat's instagram"; + elmAboutPanel.innerHTML = "Hallo Pujan ;)"; elmLengthPanel = document.createElement("div"); elmLengthPanel.className = "snake-panel-component"; diff --git a/webpack.config.js b/webpack.config.js deleted file mode 100644 index 17b96eeb..00000000 --- a/webpack.config.js +++ /dev/null @@ -1,12 +0,0 @@ -const webpack = require('webpack'); - -/* - TODO: Idea here was to make it so the game could be accessible via codesandbox.io, however, it looks like - that will require larger charges than I realized. -*/ - -module.exports = { - entry: { - app: './js/snake.js' - } -};