{"id":13565207,"url":"https://github.com/obsidiansystems/obelisk","last_synced_at":"2025-05-14T19:03:53.313Z","repository":{"id":21935422,"uuid":"134497903","full_name":"obsidiansystems/obelisk","owner":"obsidiansystems","description":"Functional reactive web and mobile applications, with batteries included.","archived":false,"fork":false,"pushed_at":"2024-10-24T02:12:09.000Z","size":19416,"stargazers_count":957,"open_issues_count":176,"forks_count":106,"subscribers_count":47,"default_branch":"master","last_synced_at":"2024-10-29T18:08:19.825Z","etag":null,"topics":["android","full-stack","haskell","ios","obelisk","web"],"latest_commit_sha":null,"homepage":"https://reflex-frp.org","language":"Haskell","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"bsd-3-clause","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/obsidiansystems.png","metadata":{"files":{"readme":"README.md","changelog":"ChangeLog.md","contributing":"CONTRIBUTING.md","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,"dei":null,"publiccode":null,"codemeta":null}},"created_at":"2018-05-23T01:53:32.000Z","updated_at":"2024-10-24T05:39:57.000Z","dependencies_parsed_at":"2023-02-19T15:30:54.662Z","dependency_job_id":"5d1d5357-64af-47ed-a25f-de7f0b92724b","html_url":"https://github.com/obsidiansystems/obelisk","commit_stats":{"total_commits":2006,"total_committers":81,"mean_commits":"24.765432098765434","dds":0.8414755732801595,"last_synced_commit":"135bfd7422b856c146b5cd5dacfe584f0621825e"},"previous_names":[],"tags_count":22,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/obsidiansystems%2Fobelisk","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/obsidiansystems%2Fobelisk/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/obsidiansystems%2Fobelisk/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/obsidiansystems%2Fobelisk/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/obsidiansystems","download_url":"https://codeload.github.com/obsidiansystems/obelisk/tar.gz/refs/heads/master","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":248710404,"owners_count":21149185,"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":["android","full-stack","haskell","ios","obelisk","web"],"created_at":"2024-08-01T13:01:42.560Z","updated_at":"2025-04-13T11:45:37.877Z","avatar_url":"https://github.com/obsidiansystems.png","language":"Haskell","funding_links":[],"categories":["Haskell","android"],"sub_categories":[],"readme":"# Obelisk\n\n[![Haskell Programming Language](https://img.shields.io/badge/language-Haskell-blue.svg)](http://www.haskell.org)\n[![BSD3 License](http://img.shields.io/badge/license-BSD3-brightgreen.svg)](https://github.com/obsidiansystems/obelisk/blob/master/LICENSE)\n\n\u003cp align=\"center\"\u003e\u003cimg src=\"docs/obelisk-logo-640.png\" width=\"50%\" alt=\"Obelisk Logo\"\u003e\u003c/p\u003e\n\nFunctional reactive web and mobile applications, with batteries included. Obelisk's goal is to represent a cohesive, highly-curated set of choices that [Obsidian Systems](https://obsidian.systems/) has made for building these types of applications in a way that is extremely fast but does not compromise on production readiness.\n\n- [Overview](#overview)\n  - [Who should consider using it?](#who-should-consider-using-it)\n- [Installing Obelisk](#installing-obelisk)\n- [Developing an Obelisk project](#developing-an-obelisk-project)\n  - [Local Hoogle](#local-hoogle)\n  - [Adding Packages](#adding-packages)\n  - [Adding Package Overrides](#adding-package-overrides)\n  - [Running tests](#running-tests)\n  - [Running over HTTPS](#running-over-https)\n  - [IDE Support](#ide-support)\n- [Deploying](#deploying)\n  - [Default EC2 Deployment](#default-ec2-deployment)\n  - [Custom Non-EC2 Deployment](#custom-non-ec2-deployment)\n    - [VirtualBox Deployment](#virtualbox-deployment)\n  - [Locally](#locally)\n  - [From macOS](#from-macos)\n  - [Deploying an updated version](#deploying-an-updated-version)\n- [Mobile](#mobile)\n  - [iOS](#ios)\n  - [Android](#android)\n- [Frequently Asked Questions (FAQ)](#frequently-asked-questions-faq)\n- [Contributing](#contributing)\n\n## Overview\n\nObelisk allows you to build high-quality web and mobile applications very quickly using [Reflex](https://reflex-frp.org/). In minutes you can go from an empty directory to an interactive application that works on web, iOS, and Android, all sharing the same Haskell codebase! Obelisk's development environment also enables extremely rapid development and feedback. You can take advantage of Haskell's type system across the frontend and backend boundary. This means changes to your backend that would break your frontend are immediately detected during development and vice versa. Obelisk uses Haskell's compiler to give you a complete \"TODO list\" of what needs to be updated.\n\nObelisk is targeted primarily at Haskell developers who want to build high-quality web and/or mobile applications in Haskell, without the distractions of manually choosing and integrating technology for every piece of the system.\n\n### Who should consider using it?\n\nObelisk assumes basic knowledge of [Haskell](https://www.haskell.org/) and [Reflex/Reflex-DOM](https://reflex-frp.org/), web technologies like [HTML](https://developer.mozilla.org/en-US/docs/Web/HTML) and [CSS](https://developer.mozilla.org/en-US/docs/Web/CSS), and a terminal shell like [Bash](https://en.wikipedia.org/wiki/Bash_(Unix_shell)). Knowledge of [Nix](https://nixos.org/) helps but is not strictly necessary.\n\n\n## Installing Obelisk\n\n1. [Install Nix](https://nixos.org/nix/).\n    If you already have Nix installed, make sure you have version 2.0 or higher.  To check your current version, run `nix-env --version`.\n1. Set up nix caches\n    1. If you are running NixOS, add this to `/etc/nixos/configuration.nix`:\n        ```nix\n        nix.binaryCaches = [ \"https://nixcache.reflex-frp.org\" ];\n        nix.binaryCachePublicKeys = [ \"ryantrinkle.com-1:JJiAKaRv9mWgpVAz8dwewnZe0AzzEAzPkagE9SP5NWI=\" ];\n        ```\n        and rebuild your NixOS configuration (e.g. `sudo nixos-rebuild switch`).\n    1. If you are using another operating system or Linux distribution, ensure that these lines are present in your Nix configuration file (`/etc/nix/nix.conf` on most systems; [see full list](https://nixos.org/nix/manual/#sec-conf-file)):\n        ```nix\n        binary-caches = https://cache.nixos.org https://nixcache.reflex-frp.org\n        binary-cache-public-keys = cache.nixos.org-1:6NCHdD59X431o0gWypbMrAURkbJ16ZPMQFGspcDShjY= ryantrinkle.com-1:JJiAKaRv9mWgpVAz8dwewnZe0AzzEAzPkagE9SP5NWI=\n        binary-caches-parallel-connections = 40\n        ```\n        * If you're on a Linux distribution other than NixOS, enable sandboxing (see these [issue 172](https://github.com/obsidiansystems/obelisk/issues/172#issuecomment-411507818) or [issue 6](https://github.com/obsidiansystems/obelisk/issues/6) if you run into build problems) by adding the following:\n          ```nix\n          sandbox = true\n          ```\n          then restart the nix daemon\n          ```bash\n          sudo systemctl restart nix-daemon\n          ```\n        * If you're on MacOS, disable sandboxing (there are still some impure dependencies for now) by adding the following:\n          ```nix\n          sandbox = false\n          ```\n          then restart the nix daemon\n          ```bash\n          sudo launchctl stop org.nixos.nix-daemon\n          sudo launchctl start org.nixos.nix-daemon\n          ```\n1. Install obelisk:\n   ```bash\n   nix-env -f https://github.com/obsidiansystems/obelisk/archive/master.tar.gz -iA command\n   ```\n\n### Accessing private repositories\n\nTo allow the Nix builder to access private git repositories, you must be set up\nto access them via SSH. Follow these steps depending on the platform you need\naccess to:\n\n- [GitHub](https://help.github.com/articles/connecting-to-github-with-ssh/)\n- [GitLab](https://docs.gitlab.com/ee/gitlab-basics/create-your-ssh-keys.html)\n\n## Developing an Obelisk project\n\nTo create a new Obelisk project, go to an empty directory and run:\n\n```bash\nob init\n```\n\nObelisk leverages ghcid to provide a live-reloading server that handles both frontend and backend. To run your Obelisk app and monitor the source for changes:\n\n```bash\nob run\n```\n\nNow, with an appropriate browser, go to http://localhost:8000 (or the address/port specified in `config/common/route`) to access your app.\nFirefox will not be able to properly run the development website due to [issue 460](https://github.com/obsidiansystems/obelisk/issues/460). Fortunately, this problem does not occur on a fully built website.\n\nEvery time you change the Haskell source files in frontend, common or backend, `ob run` will automatically recompile the modified files and reload the server. Furthermore, it will display on screen compilation errors and warnings if any.\n\n### Local Hoogle\n\nObelisk can also provide a local [Hoogle](https://hoogle.haskell.org) server that lets you browse and search the types and documentation for all of the dependencies in your entire Obelisk application. To start the Hoogle server, in a spare terminal run the following command from the root of your Obelisk application:\n\n```shell\n$ ob hoogle\n```\n\nYou can then access your local Hoogle from your web browser at `http://localhost:8080`, or by\ninstructing an editor plugin to use that address.\n\n### Adding packages\n\nIn order to add package dependencies, declare them under the build-depends field in the appropriate cabal files (backend, common, and frontend each have their own). The corresponding Nix packages will automatically be selected when building.\n\n### Adding package overrides\n\nTo add a version override to any Haskell package, or to add a Haskell package that doesn't exist in the nixpkgs used by Obelisk, use the `overrides` attribute in your project's `default.nix`. For example, to use a specific version of the `aeson` package fetched from GitHub and a specific version of the `waargonaut` package fetched from Hackage, your `default.nix` will look like:\n\n```nix\n# ...\nproject ./. ({ pkgs, ... }: {\n# ...\n  overrides = self: super: let\n    aesonSrc = pkgs.fetchFromGitHub {\n      owner = \"obsidiansystems\";\n      repo = \"aeson-gadt-th\";\n      rev = \"ed573c2cccf54d72aa6279026752a3fecf9c1383\";\n      sha256 = \"08q6rnz7w9pn76jkrafig6f50yd0f77z48rk2z5iyyl2jbhcbhx3\";\n    };\n  in\n  {\n    aeson = self.callCabal2nix \"aeson\" aesonSrc {};\n    waargonaut = self.callHackageDirect {\n      pkg = \"waargonaut\";\n      ver = \"0.8.0.1\";\n      sha256 = \"1zv28np3k3hg378vqm89v802xr0g8cwk7gy3mr77xrzy5jbgpa39\";\n    } {};\n  };\n# ...\n```\n\nFor further information see [the Haskell section](https://nixos.org/nixpkgs/manual/#users-guide-to-the-haskell-infrastructure) of nixpkgs Contributors Guide.\n\n### Adding extra local packages\n\nIf the standard packages (`frontend`, `backend`, and `common`) are not\nenough, to add more local Haskell packages, define them with the\n`packages` parameter. The sources of these packages will be\nautomatically reloaded by `ob run`.\n\n```nix\n# ...\nproject ./. ({ pkgs, ... }: {\n# ...\n  packages = {\n    another = ./another;\n  };\n# ...\n```\n\n### Running over HTTPS\n\nTo run your app locally over HTTPS, update the protocol in `config/common/route` to `https`, and then use `ob run` as normal.\n\nSince Obelisk generates a self-signed certificate for running HTTPS, the browser will issue a warning about using an invalid certificate. On Chrome, you can go to `chrome://flags/#allow-insecure-localhost` to enable invalid certificates for localhost.\n\n### IDE Support\n\nObelisk officially supports terminal-based feedback (akin to [`ghcid`](https://github.com/ndmitchell/ghcid)) in `ob run` and `ob watch`.\n\n### Using GHC 8.10\n\nObelisk currently uses GHC 8.10 for projects by default. For legacy GHC 8.6 support, add the following to your project's `default.nix`:\n\n```diff\n  { system ? builtins.currentSystem\n  , obelisk ? import ./.obelisk/impl {\n      inherit system;\n+     useGHC810 = false;\n```\n\n## Deploying\n\n### Default EC2 Deployment\n\nIn this section we will demonstrate how to deploy your Obelisk app to an Amazon EC2 instance. Obelisk deployments are configured for EC2 by default (see [Custom Non-EC2 Deployment](#custom-non-ec2-deployment)).\n\nNote: Most NixOS EC2 instances should just *work* regardless of obelisk version\n\nFirst create a new EC2 instance:\n\n1. Launch a NixOS 22.05 EC2 instance (we recommend [this AMI](https://us-east-1.console.aws.amazon.com/ec2/home?region=us-east-1#LaunchInstances:ami=ami-0223db08811f6fb2d))\n1. In the instance configuration wizard ensure that your instance has at least 1GB RAM and 10GB disk space.\n1. When prompted save your AWS private key (`~/myaws.pem`) somewhere safe. We'll need it later during deployment.\n1. Go to \"Security Groups\", select your instance's security group and under \"Inbound\" tab add a new rule for HTTP port 80 and HTTPS port 443.\n\nAt this stage your instance should be booting and become accessible shortly. Note down the hostname of your EC2 instance.\n\nNow go to your Obelisk project directory (`~/code/myapp`), and initialize a deployment config (`~/code/myapp-deploy`):\nYour project directory must be \"thunkable\", i.e. something on which `ob thunk pack` can be called. Usually it will be a git repository whose current revision has been pushed upstream.\n\nAn example set of git commands to do this is as follows (Github):\nCreate a repo using Github's UI (Public or Private)\nthen locally use these commands\n```bash\ncd ~/code/myapp\ngit init\ngit add .\ngit commit -m \"First Commit!\"\ngit remote add origin git@github.com:username/repo.git\ngit push --set-upstream origin master\n```\n\nThis will make a \"thunkable\" project that allows deployment to continue\n\nContinuing with deployment commands:\n```bash\ncd ~/code/myapp\nSERVER=ec2-35-183-22-197.ca-central-1.compute.amazonaws.com\nROUTE=https://myapp.com   # Publicly accessible route to your app\nEMAIL=myname@myapp.com\nob deploy init \\\n  --ssh-key ~/myaws.pem \\\n  --hostname $SERVER \\\n  --route $ROUTE \\\n  --admin-email $EMAIL \\\n  ~/code/myapp-deploy\n```\n\nHTTPS is enabled by default; to disable HTTPS pass `--disable-https` to the `ob deploy init` command above.\n\nThis step will also require that you manually verify the authenticity of the host `$SERVER`.\nYou can specify that you want `ob deploy init` to check your `~/.ssh/known_hosts` file and save any fingerprints matching the host to the deployment-specific configuration by passing the `--check-known-hosts` option to the `deploy init` command.\nNote that `--check-known-hosts` only works when there is a single keypair associated with a given host.\n\n\n**REMARK (Security): Obelisk deployments do *not* rely on the `known_hosts` of your local machine during deployment, only potentially during the ob deploy init, as previously mentioned.**\nThis is because, in the event that you need to switch from one deploy machine / bastion host to another, you want to be absolutely sure that you're still connecting to the machines you think you are, even if that deploy machine / bastion host has never connected to them before.\nObelisk explicitly avoids a workflow that encourages people to accept host keys without checking them, since that could result in leaking production secrets to anyone who manages to MITM you, e.g. via DNS spoofing or cache poisoning.\nNote that an active attack is a circumstance where you may need to quickly switch bastion hosts, e.g. because the attacker has taken one down or you have taken it down in case it was compromised.\nIn this circumstance you might need to deploy to production to fix an exploit or rotate keys, etc.\nWhen you run `ob deploy` later it will rely on the saved verification in this step.\n\nNext, go to the deployment directory that you just initialized and deploy!\n\n```bash\ncd ~/code/myapp-deploy\nob deploy push\n```\n\n`ob deploy push` will locally build your app and then transfer it, along with all the Nix package dependencies, via ssh to the EC2 instance. The backend will live in `/var/lib/backend`.\n\nAt this point you are done. Your app will be accessible at `${ROUTE}`. The currently deployed version - the git commit hash of the source repo - can be found at `${ROUTE}/version`.\n\n### Custom Non-EC2 Deployment\n\nBy default Obelisk deployments are configured for NixOS machines running on AWS EC2. To provide your own configuration, you need to write a custom `module.nix` in the deployment repository. This still requires that your server is running NixOS.\n\n`module.nix` must contain a Nix *function* that produces a [NixOS module function](https://nixos.org/nixos/manual/index.html#sec-writing-modules). The top-level function takes deployment configuration as arguments: `hostName`, `adminEmail`, `routeHost`, `enableHttps`, `version`, `exe`, `nixosPkgs`. Most of these are the values you specified during `ob deploy init` and are stored in the deployment repository. `version` is a `git` hash for the app that you're deploying. `exe` is the Linux build of the app (as seen in [Deploying Locally](#locally)). `nixosPkgs` is the package set used to construct the NixOS VM.\n\nThe [VirtualBox Deployment](#virtualbox-deployment) section provides an example.\n\n#### VirtualBox Deployment\n\nHere's a `module.nix` that is configured for deployment to a VirtualBox VM (running NixOS):\n\n```nix\n{ nixosPkgs, ... }: {...}: {\n  imports = [ (nixosPkgs.path + /nixos/modules/virtualisation/virtualbox-image.nix) ];\n}\n```\n\nThe `{...}:` and following is the [NixOS module](https://nixos.org/nixos/manual/index.html#sec-writing-modules) definition.\n\n### Locally\n\nIf you want deploy your application locally or test a production-oriented build you can build and deploy the app as described below.\n\nBuild the application:\n\n```bash\nnix-build -A exe --no-out-link\n```\n\nCopy the result to a new directory, add configuration, and run!\n\n```bash\nmkdir test-app\nln -s $(nix-build -A exe --no-out-link)/* test-app/\ncp -r config test-app\n(cd test-app \u0026\u0026 ./backend)\n```\n\n### From macOS\n\nDeploying from macOS requires some extra setup:\n\n- [Install nix-darwin](https://github.com/LnL7/nix-darwin)\n- [Install docker](https://docs.docker.com/)\n\nRunning `ob deploy push` will give you additional setup instructions.\n\n### Deploying an updated version\n\nIf you'd like to deploy an updated version (with new commits) of your Obelisk app: simply go to the configuration directory, update the source thunk and push:\n\n```bash\ncd ~/code/myapp-deploy\nob deploy update\nob deploy push\n```\n\n### Host Redirection\n\nA `redirect_hosts` file can be added in the deployment directory (`~/code/myapp-deploy` in the example above), allowing you to specify alternative domain names that will redirect to the deployment domain.\nThis feature assumes the apropriate CNAME records have been added with a domain registration service.\n\nAdd one domain per line in `redirect_hosts`.\nAll listed domains will redirect to the publicly accessible domain specified by `ob deploy init`.\nFor clarity, this is the `$ROUTE` variable in the EC2 deployment example shown earlier.\nThe following is an example of a `~/code/myapp-deploy/redirect_hosts` file:\n\n```\nwww.foo.com\nwww.bar.com\n```\n\n*Caveat*: Your https certificates will cover all your domains automatically, although you may need to force a recertification manually.\nWe assume you have root access to the deployment EC2 instance.\nContinuing from the `ob init deploy` example above:\n\n```bash\nssh root@ec2-35-183-22-197.ca-central-1.compute.amazonaws.com\n\nEMAIL=myname@myapp.com\nROUTE_TO=myapp.com\nROUTE_FROM=foo.com\nROUTE_FROM_2=bar.com\n/nix/store/`ls /nix/store | grep lego`/bin/lego \\\n  -d $ROUTE_TO \\\n  --email $EMAIL \\\n  --path . \\\n  --key-type ec256 \\\n  --accept-tos \\\n  -d $ROUTE_FROM \\\n  -d $ROUTE_FROM_2 \\\n  --http \\\n  --http.webroot /var/lib/acme/acme-challenge run\n```\n\n## Mobile\nUntil Obelisk offers a `ob deploy` equivalent for mobile apps, you are recommended to do it manually as follows.\n\n### iOS\n\n#### First time setup\nDevelopment on iOS requires a computer running macOS and an iOS developer account.\nYour account must also belong to an Apple Developer Team, if you want to access developer portal links (otherwise they'll redirect to your account page).\n\n##### iPhone\n1. Connect the iPhone on which you'd like to run builds - this will open up iTunes.\n1. Click accept to authorize on both the computer and the iPhone.\n\n##### Xcode\nInstall Xcode 11.2 (contains iOS SDK 13.2) and open it so that it runs its post install tool setup.\n\nThese versions will work out of the box but iOS SDKs prior to 11.3 should also work. You can choose another installed version in `default.nix`\n\nMore recent Xcodes should also work, as long as one of the SDKs mentioned above has been used.\nTo add another SDK to your current Xcode, [download](https://developer.apple.com/download/more/) the corresponding Xcode, extract it and copy its SDK folder next to the installed one, e.g.\n```bash\nopen -W Xcode_9.2.xip\nsudo cp -R Xcode.app/Contents/Developer/Platforms/iPhoneOS.platform/Developer/SDKs/iPhoneOS.sdk /Applications/Xcode.app/Contents/Developer/Platforms/iPhoneOS.platform/Developer/SDKs/iPhoneOS11.2.sdk\n```\n\n\nYou can verify that you have correct versions by running\n```bash\nxcodebuild -showsdks\n```\n\n##### Certificates\nTo deploy and/or package apps, you'll need to inform Apple of your development devices and permissions by\nadding credentials to the correct provisioning profile via the Apple Developer portal.\n\n1. Open up XCode and go to Preferences - Accounts. Select the organization\nMember role, click Manage Certificates, and add an iOS Development\ncertificate.\n1. Go to [developer portal - devices](https://developer.apple.com/account/ios/device/) and add your device.\nTo find your device's UDID, select it in iTunes and click the serial number.\n1. Go to [developer portal - development profiles](https://developer.apple.com/account/ios/profile/limited).\nCreate a development profile and add your certificate and device.\nClick \"Generate\" and then download and open the profile.\n\n#### Building\n1. In your project's `default.nix` set values for `ios.bundleIdentifier` and `ios.bundleName`.\nEnsure that `bundleIdentifier` matches the App ID of the development profile, or that you are using a wildcard profile.\n1. Run `nix-build -A ios.frontend -o result-ios` to build the app. Find it at `result-ios/frontend.app`\n\n#### Deploying\n1. Connect the registered iPhone.\n1. Find your Apple Team ID in the [developer portal](https://developer.apple.com/account/#/membership).\n1. Run the deploy command with your Team ID:\n```bash\nresult-ios/bin/deploy [TEAM_ID]\n# or in debug mode via lldb:\nresult-ios/bin/deploy [TEAM_ID] -d\n```\n\n#### Packaging\n1. Go to [developer portal - distribution profiles](https://developer.apple.com/account/ios/profile/production).\nCreate and download a distribution profile.\n1. Run the package script with your TEAM ID and your distribution profile to create a `.ipa`:\n```bash\nresult-ios/bin/package [TEAM_ID] /path/to/output/.ipa /path/to/profile/file\n```\n\n#### Debugging\nIt's also possible to inspect iOS WkWebView apps once they are installed in the iPhone:\n1. On the desktop, go to Safari \u003e Preferences \u003e Advanced and enable Develop menu.\n1. On the iPhone go to Settings \u003e Safari \u003e Advanced and enable Web Inspector.\n1. Open the app on the iPhone while it is connected to the desktop.\n1. In the desktop's Safari Develop menu, you should see your iPhone. Select the screen under the name of the app.\n\n### Android\n\nNOTE: Currently Android builds are only supported on Linux.\n\n1. In your project's `default.nix` set a suitable value for `android.applicationId` and `android.displayName`.\n1. In your project's `default.nix` pass `config.android_sdk.accept_license = true;` in the arguments to the import of of `.obelisk/impl` to indicate your acceptance of the [Android Software Development Kit License Agreement](https://developer.android.com/studio/terms), which is required to build Android apps.\n1. Run `nix-build -A android.frontend -o result-android` to build the Android app.\n1. A debug version of the app should be generated at `result-android/android-app-debug.apk`\n\nNow deploy the built apk file to your Android device:\n\n1. Enable *USB debugging* in your Android device ([instructions here](https://developer.android.com/studio/debug/dev-options))\n1. Connect the device using USB (be sure to confirm any security prompts on the device)\n1. Run the deploy script: `result-android/bin/deploy`\n\nAlternatively, you can deploy from an obelisk deployment directory (a directory generated post `ob deploy init ...` command) using the `ob deploy test android` command.\nThis command will accomplish the following:\n\n1. Create a key store and apk signing key (`android_keystore.jks`)\n1. Build a Signed Android apk for your application\n1. Deploy the Signed apk to your connected Android device\n\nIn the event that you change your key or keystore password, you will have to update your credentials within the JSON object found in `android_keytool_config.json`.\n\nAdditional documentation on Java key stores can be found [here](https://docs.oracle.com/javase/8/docs/technotes/tools/unix/keytool.html).\n\nThis should copy over and install the application on your device (if you see a  \"*signatures do not match*\" error, simply uninstall the previous app from the device before retrying the deploy). The name of the installed application will be what you have specified for `android.displayName` in the `default.nix`.\n\n#### Releasing to Play Store\n\n##### Build a release version\n\nAfter having configured signing for your app, you may proceed to build a release version of the app. This is no different to how you build the non-release version, so consult the section [Android](#android) further above for exact instructions on building and deploying to your device.\n\n\n## Frequently Asked Questions (FAQ)\n\nRefer to [FAQ](FAQ.md).\n\n\n## Contributing\n\nContributions and issue reports are encouraged and appreciated! Refer to the [Contributing](CONTRIBUTING.md) guide for information about getting started.\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fobsidiansystems%2Fobelisk","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fobsidiansystems%2Fobelisk","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fobsidiansystems%2Fobelisk/lists"}