We are currently working towards the first major release of MewsFeed.
Collaborate on GitHub and join our Discord!
Come join us on mewsfeed. We're talking at the hashtags #mewsfeed and #holochain. Share your feedback by tagging #mewsfeedback!
You can follow the team on mewsfeed at:
@artbrock @zippy @mattyg @jost
- Install the holochain dev environment (only nix-shell is required): https://developer.holochain.org/docs/install/
- Enable Holochain cachix with:
nix-env -iA cachix -f https://cachix.org/api/v1/install
cachix use holochain-ci- Clone this repo and
cdinside of it. - Enter the nix shell by running this in the root folder of the repository:
nix develop
npm installThis will install all the needed dependencies in your local environment, including holochain, hc and npm.
- Build the DNA (assumes you are still in the nix shell for correct rust/cargo versions from step above):
npm run build:happnpm run testTo test out the UI:
npm startTo run another agent, open another terminal, and execute again:
npm startEach new agent that you create this way will get assigned its own port and get connected to the other agents.
The deploy/local-dev.sh script manages local infrastructure for testing with the Holo Web Conductor browser extension. It starts conductors, a bootstrap server, the h2hc-linker, and optionally a joining service.
- Nix develop shell (
nix develop) - Sibling repo checkouts (see layout below)
- h2hc-linker built at
../h2hc-linker(or setH2HC_LINKER_DIR) - joining-service at
../joining-service(or setJOINING_SERVICE_DIR) — only needed for joining mode - The HWC browser extension installed
All HWC-related repos must be siblings in the same parent directory:
parent/
├── mewsfeed/ # This repo
├── holo-web-conductor/ # Required (provides client library)
├── joining-service/ # Optional (for joining mode)
└── h2hc-linker/ # Required (linker binary)
Run the setup script from holo-web-conductor to verify the layout and build dependencies:
cd ../holo-web-conductor
nix develop -c ./scripts/holo-dev-setup.shUse --clone to automatically clone missing repos, or --download-linker to fetch a prebuilt linker binary instead of building from source.
Then install this repo's dependencies:
cd ../mewsfeed
nix develop -c npm installBasic mode (no joining service, direct linker connection):
npm run start:hwcWith joining service (invite code auth, default):
npm run start:hwc:joiningWith email code auth (verification codes written to files):
AUTH_METHOD=email_code npm run start:hwc:joiningEmail codes are written to /tmp/mewsfeed-local-dev/dev-emails/. Read the file to get the verification code.
With email code + hc_auth integration:
AUTH_METHOD=email_code \
HC_AUTH_URL=https://hc-auth-server.example.com \
HC_AUTH_TOKEN=your-api-token \
npm run start:hwc:joining| Variable | Default | Description |
|---|---|---|
AUTH_METHOD |
invite_code |
Auth method: invite_code, email_code, open |
INVITE_CODES |
test-invite-123 |
Comma-separated invite codes (for invite_code method) |
EMAIL_OUTPUT_DIR |
/tmp/mewsfeed-local-dev/dev-emails |
Directory for email-to-file dev emails |
HC_AUTH_URL |
(empty) | hc_auth server URL (enables hc_auth notification on join) |
HC_AUTH_TOKEN |
(empty) | hc_auth API bearer token |
HC_AUTH_FORWARD_CLAIMS |
(empty) | Comma-separated claim keys to forward to hc_auth (e.g. email,phone) |
JOINING_SERVICE_DIR |
../joining-service |
Path to joining-service repo |
H2HC_LINKER_DIR |
../h2hc-linker |
Path to h2hc-linker repo |
JOINING_SERVICE_PORT |
3000 |
Joining service port |
LINKER_PORT |
8000 |
Linker port |
NUM_CONDUCTORS |
2 |
Number of holochain conductors to start |
LINKER_ADMIN_SECRET |
local-dev-secret |
Linker admin secret |
./deploy/local-dev.sh status # Show running services
./deploy/local-dev.sh stop # Stop all servicesFor deploying mewsfeed with the Holo Web Conductor (HWC) browser extension, see deploy/DEPLOY.md.
To package the web happ:
npm run packageYou'll have the mewsfeed.webhapp in workdir. This is what you should distribute so that the Holochain Launcher can install it.
You will also have its subcomponent mewsfeed.happ in the same folder`.
We are using this tooling:
- NPM Workspaces: npm v7's built-in monorepo capabilities.
- hc: Holochain CLI to easily manage Holochain development instances.
- @holochain/tryorama: test framework.
- @holochain/conductor-api: client library to connect to Holochain from the UI.