Attention, please.
This code is a work in progress, and we publish it for full transparency. You can review the source code, but:
- you shouldn't just run this code without reading it, as it may have bugs or stubbed out crypto
- it might not do exactly what it says it is doing
If you really want to install Keybase, please return to the repo README.md for official release instructions.
This directory is an exploration of using react-native alongside React in Electron.
It's an early prototype, not ready for use yet.
To run:
npm install
npm start
Available npm run commands:
npm start
: Build a development bundle and start the app off of those files (If you're running the app once)hot-server
: Start the hot-reloading serverstart-hot
: Connect to a hot-reloading server (If you're developing and want to see changes as you make them)build-dev
: Build a development bundlebuild-prod
: Build a production bundlestart-cold
: Start the app off of the build-dev bundlespackage
: Make an electron application build
Environment variables:
HOME
: Home dir to use, useful for multiple installsKEYBASE_RUN_MODE
: production, staging, develKEYBASE_LOCAL_DEBUG
(bool): DebugKEYBASE_SHOW_DEVTOOLS
(bool): Show devtoolsKEYBASE_FEATURES
: Feature flagsKEYBASE_RPC_DELAY
: Number of ms to delay all RPC calls (requires debug mode)KEYBASE_RPC_DELAY_RESULT
: Number of ms to delay all RPC call callbacks (requires debug mode)
Getting sourcemaps to work in the production app:
Download the matching sourcemaps from the build folder. Run the following npm command, passing the path to the unzipped path
npm run inject-sourcemaps-prod -- /mysourcemaps/Keybase-1.0.7-20160111080008+1049d47.map
This will copy the sourcemaps into the application package (if installed in the default location). Otherwise you can just do this yourself
If you have a crash of a non-sourcemapped build (like a screenshot with a crash) you can do a post-mortem debug of the minimized code by using a utility.
npm install -g sourcemap-finder
smfinder --position 1200:10 path-to-your-source-map
- Remove old shrinkwrap: Run
rm npm-shrinkwrap.json
- Find outdated packages: Run
npm outdated
- Install updated packages: Run
npm install -E -S packageName@specificVersion
ornpm install -E -D devPackageName@specificVersion
Dependencies are shrinkwrapped in this repository. Vendored copies of dependencies are located in keybase/js-vendor-desktop.
First, commit your changes to package.json
. Then, to update the shrinkwrap and re-vendor dependencies, you'll need to clone keybase/js-vendor-desktop and run:
KEYBASE_JS_VENDOR_DIR=path/to/js-vendor-desktop npm run vendor-update
This will create a new commit in this repo and js-vendor-desktop containing the updated deps.