diff --git a/.gitignore b/.gitignore index 7091e6f..2cabec8 100644 --- a/.gitignore +++ b/.gitignore @@ -1,8 +1,6 @@ -appero/node_modules/* -appero/package-lock.json -appero/yarn.lock -appero/MACOSX* - -.DS_Store - -appero/.installed +installation/baseapp/node_modules +installation/baseapp/package-lock.json +installation/baseapp/yarn.lock +installation/baseapp/tmp +.trunk +.DS_Store \ No newline at end of file diff --git a/Appero! b/Appero! deleted file mode 100755 index cdfe3a2..0000000 --- a/Appero! +++ /dev/null @@ -1,39 +0,0 @@ -#!/bin/zsh -mydir=${0:a:h} -cd $mydir -echo $mydir -cd appero - - -# Check for installed file -if [ ! -f .installed ]; then - echo "Installing appero..." - # Install Homebrew - if [ ! -f /opt/homebrew/bin/brew ]; then - echo "Installing Homebrew..." - /bin/bash -c "$(curl -fsSL https://raw.githubusercontent.com/Homebrew/install/HEAD/install.sh)" - else - echo "Homebrew already installed" - fi - - if which node > /dev/null - then - echo "node is installed, skipping..." - else - echo "Installing node..." - # Install Homebrew packages - brew install node - fi - - # Install npm packages - echo "Installing npm packages..." - npm install - - touch .installed -fi - -echo "Starting appero..." - -# Run -node appero.js - diff --git a/README.md b/README.md index a5d6b96..8fd720c 100644 --- a/README.md +++ b/README.md @@ -1,18 +1,4 @@ -# Appero +# Appetite (was Appero'!) +The simplest and lightest way to transform websites into native apps - - - -## The easiest way to create a native application from any website - -### Installation and usage - -Download the release and double click on Appero! or: - - git clone https://github.com/thecookingsenpai/appero && cd appero - ./Appero! - - -At the first launch Appero might have to download and install node.js, brew and the required packages. This will happens only once. - -Once finished, the application will be available in the appero/apps folder. +## Work in Progress \ No newline at end of file diff --git a/appero/appero.js b/appero/appero.js deleted file mode 100644 index c6a8944..0000000 --- a/appero/appero.js +++ /dev/null @@ -1,68 +0,0 @@ -const fse = require('fs-extra'); -var request = require("request"); -const decompress = require("decompress"); -const prompt = require("prompt-sync")({ sigint: true }); - -var url = prompt("URL: "); -var name = prompt("Name: "); - -decompress("baseapp.zip", "./") - .then(() => { - main(); - }) - -function main() { - - // Arguments parsing - console.log(url) - // Safety check - if(!url) { - console.error('No URL specified'); - process.exit(1); - } else if ( (!url.startsWith('http://')) && (!url.startsWith('https://')) ) { - console.error('URL must start with http:// or https://'); - process.exit(1); - } - // Trying to get favicon - try { - var stream = request(url + "/favicon.ico").pipe(fse.createWriteStream('favicon.ico')) - stream.on('finish', function () { - if (fse.existsSync("favicon.ico")) { - finalWrap(true) - } - }) - } catch (err) { - console.log("No favicon") - finalWrap(false) - } - - -} - - -function finalWrap(fav) { - // Wrapping with random id - var folder_name - if (name==="") { - var rid = Math.floor(Math.random() * 8192); - folder_name = "./apps/app_" + rid - } else { - folder_name = name; - } - fse.copySync("./baseapp.app", folder_name) - // Writing location - fse.writeFileSync(folder_name + "/Contents/MacOS/location.config", url, "utf8") - // Changing name - var plist = fse.readFileSync(folder_name + "/Contents/Info.plist", "utf8") - var newPlist = plist.replace("Appero Native App", folder_name) - fse.writeFileSync(folder_name + "/Contents/Info.plist", newPlist, "utf8") - // Icon - if (fav) { - fse.removeSync(folder_name + "/Contents/Resources/electron.icns") - fse.moveSync("favicon.ico", folder_name + "/Contents/Resources/electron.icns") - } - // Packing - fse.moveSync(folder_name, folder_name + ".app") - fse.removeSync("baseapp.app") - console.log('Done'); -} \ No newline at end of file diff --git a/appero/baseapp.zip b/appero/baseapp.zip deleted file mode 100644 index d4c187e..0000000 Binary files a/appero/baseapp.zip and /dev/null differ diff --git a/appero/package.json b/appero/package.json deleted file mode 100644 index 47a371d..0000000 --- a/appero/package.json +++ /dev/null @@ -1,17 +0,0 @@ -{ - "name": "appero", - "version": "1.0.0", - "description": "URLs to native apps", - "main": "appero.js", - "scripts": { - "test": "echo \"Error: no test specified\" && exit 1" - }, - "author": "TCSenpai", - "license": "ISC", - "devDependencies": { - "fs-extra": "^11.1.0", - "prompt-sync": "^4.2.0", - "request": "^2.88.2", - "decompress": "^4.2.1" - } -} diff --git a/installation/.github/CODEOWNERS b/installation/.github/CODEOWNERS new file mode 100644 index 0000000..7639191 --- /dev/null +++ b/installation/.github/CODEOWNERS @@ -0,0 +1 @@ +* @electron/wg-ecosystem diff --git a/installation/.github/dependabot.yml b/installation/.github/dependabot.yml new file mode 100644 index 0000000..3a1f0c4 --- /dev/null +++ b/installation/.github/dependabot.yml @@ -0,0 +1,9 @@ +version: 2 +updates: +- package-ecosystem: npm + directory: "/" + schedule: + interval: daily + time: "13:00" + open-pull-requests-limit: 99 + versioning-strategy: increase diff --git a/installation/.github/workflows/add-to-project.yml b/installation/.github/workflows/add-to-project.yml new file mode 100644 index 0000000..60b1cb7 --- /dev/null +++ b/installation/.github/workflows/add-to-project.yml @@ -0,0 +1,29 @@ +name: Add to Ecosystem WG Project + +on: + issues: + types: + - opened + pull_request_target: + types: + - opened + +permissions: {} + +jobs: + add-to-project: + runs-on: ubuntu-latest + steps: + - name: Generate GitHub App token + uses: electron/github-app-auth-action@384fd19694fe7b6dcc9a684746c6976ad78228ae # v1.1.1 + id: generate-token + with: + creds: ${{ secrets.ECOSYSTEM_ISSUE_TRIAGE_GH_APP_CREDS }} + org: electron + - name: Add to Project + uses: dsanders11/project-actions/add-item@3a81985616963f32fae17d1d1b406c631f3201a1 # v1.1.0 + with: + field: Opened + field-value: ${{ github.event.pull_request.created_at || github.event.issue.created_at }} + project-number: 89 + token: ${{ steps.generate-token.outputs.token }} diff --git a/installation/baseapp/baselauncher b/installation/baseapp/baselauncher new file mode 100644 index 0000000..89d51f9 --- /dev/null +++ b/installation/baseapp/baselauncher @@ -0,0 +1,2 @@ + +echo { \"target_url\": \"$URL\" } > $HOME/.config/appetite/config.json && yarn start . diff --git a/installation/baseapp/index.html b/installation/baseapp/index.html new file mode 100644 index 0000000..4ec7052 --- /dev/null +++ b/installation/baseapp/index.html @@ -0,0 +1,12 @@ + + +
+ + + +