lbry-desktop/README.md

103 lines
4.3 KiB
Markdown
Raw Normal View History

2017-02-20 21:50:06 +01:00
# LBRY App
2017-01-16 20:06:53 +01:00
2017-03-09 18:31:07 +01:00
This is a graphical browser for the decentralized content marketplace provided by the [LBRY](https://lbry.io) protocol. It is essentially the [lbry daemon](https://github.com/lbryio/lbry) bundled with a UI using [Electron](http://electron.atom.io/).
2017-01-16 20:06:53 +01:00
2017-06-02 00:24:20 +02:00
![App Screenshot](https://lbry.io/img/lbry-ui.png)
2017-02-21 19:10:20 +01:00
## Installing
2017-01-18 17:32:01 +01:00
We provide installers for Windows, macOS, and Debian-based Linux.
2017-05-19 16:30:13 +02:00
| | Windows | macOS | Linux |
| --- | --- | --- | --- |
| Latest Stable Release | [Download](https://lbry.io/get/lbry.exe) | [Download](https://lbry.io/get/lbry.dmg) | [Download](https://lbry.io/get/lbry.deb) |
| Latest Prerelease | [Download](https://lbry.io/get/lbry.pre.exe) | [Download](https://lbry.io/get/lbry.pre.dmg) | [Download](https://lbry.io/get/lbry.pre.deb) |
Our [releases page](https://github.com/lbryio/lbry-app/releases/latest) also contains the latest release, pre-releases, and past builds.
2017-01-16 20:06:53 +01:00
2017-02-21 19:10:20 +01:00
To install from source or make changes to the application, continue reading below.
2017-01-16 20:06:53 +01:00
## Development on Linux and macOS
2017-01-16 20:06:53 +01:00
2017-06-02 00:20:29 +02:00
### One-time Setup
2017-01-16 20:06:53 +01:00
1. Clone this repo
2017-11-10 16:47:51 +01:00
2. `DEPS=true ./build.sh`
2017-11-10 17:49:22 +01:00
This will download and install the LBRY app and its dependencies, including [the LBRY daemon](https://github.com/lbryio/lbry) and command line utilities like `node` and `yarn`. The LBRY app requires Node >= 6; if you have an earlier version of Node installed and want to keep it, you can use [nvm](https://github.com/creationix/nvm) to switch back and forth.
2017-01-16 20:06:53 +01:00
2017-06-02 00:20:29 +02:00
### Running
2017-01-16 20:06:53 +01:00
2017-11-24 15:31:05 +01:00
Run `./node_modules/.bin/electron src/main`
2017-02-20 21:50:06 +01:00
2017-06-02 00:20:29 +02:00
### Ongoing Development
2017-11-24 15:31:05 +01:00
1. `cd src/renderer`
2017-06-02 00:20:29 +02:00
2. `./watch.sh`
2017-02-20 21:50:06 +01:00
2017-11-24 15:31:05 +01:00
This will set up a monitor that will automatically compile any changes to JS or CSS folders inside of the `src/renderer` folder. This allows you to make changes and see them immediately by reloading the app.
2017-01-16 20:06:53 +01:00
2017-06-02 00:20:29 +02:00
### Packaging
2017-01-16 20:06:53 +01:00
2017-02-20 21:50:06 +01:00
We use [electron-builder](https://github.com/electron-userland/electron-builder)
to create distributable packages, which is run by calling:
2017-01-16 20:06:53 +01:00
2017-02-20 21:50:06 +01:00
`node_modules/.bin/build -p never`
2017-02-21 19:10:20 +01:00
## Development on Windows
2017-02-21 19:10:20 +01:00
### Windows Dependency
1. Download and install `git` from <a href="https://git-for-windows.github.io/">github.io<a> (configure to use command prompt integration)
2. Download and install `npm` and `node` from <a href="https://nodejs.org/en/download/current/">nodejs.org<a>
3. Download and install `python 2.7` from <a href="https://www.python.org/downloads/windows/">python.org</a>
4. Download and Install `Microsoft Visual C++ Compiler for Python 2.7` from <a href="https://www.microsoft.com/en-us/download/confirmation.aspx?id=44266">Microsoft<a>
5. Download and install `.NET Framework 2.0 Software Development Kit (SDK) (x64)` from <a href="https://www.microsoft.com/en-gb/download/details.aspx?id=15354">Microsoft<a> (may need to extract setup.exe and install manually by running install.exe as Administrator)
### One-time Setup
1. Open command prompt as adminstrator and run the following:
```
npm install --global --production windows-build-tools
exit
```
2. Open command prompt in the root of the project and run the following:
```
python -m pip install -r build\requirements.txt
npm install -g yarn
yarn install
```
2017-11-28 01:01:33 +01:00
2017-11-27 12:52:11 +01:00
3. Change directory to `src\main` and run the following:
```
yarn install
node_modules\.bin\electron-rebuild
node_modules\.bin\electron-rebuild
2017-11-24 15:31:05 +01:00
cd ..\..
```
2017-11-24 15:31:05 +01:00
4. Change directory to `src\renderer` and run the following:
```
yarn install
npm rebuild node-sass
node node_modules\node-sass\bin\node-sass --output dist\css --sourcemap=none scss\
node_modules\.bin\webpack --config webpack.dev.config.js
2017-11-24 15:31:05 +01:00
xcopy /E dist ..\main\dist
cd ..\..
```
2017-11-24 15:31:05 +01:00
4. Download the lbry daemon and cli [binaries](https://github.com/lbryio/lbry/releases) and place them in `src\main\dist\`
### Building lbry-app
1. run `node_modules\.bin\build -p never` from the root of the project.
### Running the electron app
2017-11-24 15:31:05 +01:00
1. Run `node_modules\.bin\electron src\main`
### Ongoing Development
2017-11-24 15:31:05 +01:00
1. `cd src\renderer`
2. `watch.bat`
2017-11-24 15:31:05 +01:00
This will set up a monitor that will automatically compile any changes to JS or CSS folders inside of the `src\renderer` folder. This allows you to make changes and see them immediately by reloading the app.
2017-05-31 12:59:58 +02:00
## Internationalization
2017-11-24 15:31:05 +01:00
If you want to help translating the lbry-app, you can copy the en.json file in /src/main/locales and modify the values while leaving the keys as their original English strings. An example for this would be: `"Skip": "Überspringen",` Translations should automatically show up in options.