Skip to content

Commit

Permalink
update yarn naming
Browse files Browse the repository at this point in the history
  • Loading branch information
arjanjohan committed Jul 8, 2024
1 parent 54660c2 commit a2f2234
Show file tree
Hide file tree
Showing 5 changed files with 57 additions and 39 deletions.
17 changes: 9 additions & 8 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -36,30 +36,31 @@ cd scaffold-move
yarn install
```

<!-- 2. Run a local network in the first terminal:
2. ~~Run a local network in the first terminal:~~

```
<!-- ```
yarn chain
``` -->

Movement M1 devnet is hardcoded in this version of Scaffold-Move, so we skip this step.

2. On a second terminal, initialize a new account.
3. On a second terminal, initialize a new account.

```
yarn account
```

This command overwrites `packages/move/.aptos/config.yaml` with a new Aptos account. The new address is copied over to the first address in the Move.toml file. If no address exists in this file, it is added on a new line.

3. Deploy the test contract:
4. Deploy the test contract:

```
yarn deploy
```

This command deploys a test smart contract to the local network. The contract is located in `packages/hardhat/contracts` and can be modified to suit your needs. The `yarn deploy` command uses `movement aptos move publish` to publish the contract to the network. After this is executes the script located in `scripts/loadContracts.js` to make the new contracts available in the nextjs frontend.

4. On a third terminal, start your NextJS app:
5. On a third terminal, start your NextJS app:

```
yarn start
Expand All @@ -77,7 +78,7 @@ Visit your app on: `http://localhost:3000`. You can interact with your smart con

For this hackathon I kept the scope small due to the time constraints. I build only the most essential and useful features, so that developers can start using Scaffold Move right away. However, there is much more that I want to add to this project after the hackathon. If you have any ideas or suggestions, please reach out and I will add it to this list.

- Styling wallet connect button
- Styling wallet connect button + add dropdown
- Store network data in scaffold-config
- Debug page
- Msg for no result on view methods
Expand All @@ -87,8 +88,8 @@ For this hackathon I kept the scope small due to the time constraints. I build o

## Links

- [Presentation video]()
- [Presentation slides]()
<!-- - [Presentation video]()
- [Presentation slides]() -->
- [Website](https://scaffold-move-chi.vercel.app/)

## Team
Expand Down
28 changes: 14 additions & 14 deletions package.json
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
{
"name": "se-2",
"name": "scaffold-move",
"version": "0.0.1",
"private": true,
"workspaces": {
Expand All @@ -9,22 +9,22 @@
]
},
"scripts": {
"account": "cd packages/move && [ ! -f .aptos/config.yaml ] || rm .aptos/config.yaml; echo '' | movement aptos init --network custom --rest-url https://devnet.m1.movementlabs.xyz/ --faucet-url https://devnet.m1.movementlabs.xyz/ --assume-no && node ../../scripts/account.js",
"chain": "",
"deploy": "cd packages/move && movement aptos move publish && node ../../scripts/loadContracts.js",
"compile": "",
"account": "yarn workspace @scaffold-move/move account && node scripts/account.js",
"chain": "yarn workspace @scaffold-move/move chain",
"deploy": "yarn workspace @scaffold-move/move publish && node scripts/loadContracts.js",
"compile": "yarn workspace @scaffold-move/move compile",
"test": "",
"format": "yarn next:format && yarn hardhat:format",
"start": "yarn workspace @se-2/nextjs dev",
"next:lint": "yarn workspace @se-2/nextjs lint",
"next:format": "yarn workspace @se-2/nextjs format",
"next:check-types": "yarn workspace @se-2/nextjs check-types",
"next:build": "yarn workspace @se-2/nextjs build",
"next:serve": "yarn workspace @se-2/nextjs serve",
"format": "yarn next:format",
"start": "yarn workspace @scaffold-move/nextjs dev",
"next:lint": "yarn workspace @scaffold-move/nextjs lint",
"next:format": "yarn workspace @scaffold-move/nextjs format",
"next:check-types": "yarn workspace @scaffold-move/nextjs check-types",
"next:build": "yarn workspace @scaffold-move/nextjs build",
"next:serve": "yarn workspace @scaffold-move/nextjs serve",
"postinstall": "husky install",
"precommit": "lint-staged",
"vercel": "yarn workspace @se-2/nextjs vercel",
"vercel:yolo": "yarn workspace @se-2/nextjs vercel:yolo"
"vercel": "yarn workspace @scaffold-move/nextjs vercel",
"vercel:yolo": "yarn workspace @scaffold-move/nextjs vercel:yolo"
},
"packageManager": "[email protected]",
"devDependencies": {
Expand Down
11 changes: 11 additions & 0 deletions packages/move/package.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,11 @@
{
"name": "@scaffold-move/move",
"packageManager": "[email protected]",
"scripts": {
"account": "[ ! -f .aptos/config.yaml ] || rm .aptos/config.yaml; echo '' | movement aptos init --network custom --rest-url https://devnet.m1.movementlabs.xyz/ --faucet-url https://devnet.m1.movementlabs.xyz/",
"chain": "movement aptos node run-local-testnet",
"publish": "movement aptos move publish",
"compile": "movement aptos move compile",
"test": ""
}
}
2 changes: 1 addition & 1 deletion packages/nextjs/package.json
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
{
"name": "@se-2/nextjs",
"name": "@scaffold-move/nextjs",
"private": true,
"version": "0.1.0",
"scripts": {
Expand Down
38 changes: 22 additions & 16 deletions yarn.lock
Original file line number Diff line number Diff line change
Expand Up @@ -2058,9 +2058,29 @@ __metadata:
languageName: node
linkType: hard

"@se-2/nextjs@workspace:packages/nextjs":
"@se-2/move@workspace:packages/move":
version: 0.0.0-use.local
resolution: "@se-2/nextjs@workspace:packages/nextjs"
resolution: "@se-2/move@workspace:packages/move"
languageName: unknown
linkType: soft

"@sinclair/typebox@npm:0.25.24":
version: 0.25.24
resolution: "@sinclair/typebox@npm:0.25.24"
checksum: 10219c58f40b8414c50b483b0550445e9710d4fe7b2c4dccb9b66533dd90ba8e024acc776026cebe81e87f06fa24b07fdd7bc30dd277eb9cc386ec50151a3026
languageName: node
linkType: hard

"@sindresorhus/is@npm:^4.0.0":
version: 4.6.0
resolution: "@sindresorhus/is@npm:4.6.0"
checksum: 83839f13da2c29d55c97abc3bc2c55b250d33a0447554997a85c539e058e57b8da092da396e252b11ec24a0279a0bed1f537fa26302209327060643e327f81d2
languageName: node
linkType: hard

"@sm/nextjs@workspace:packages/nextjs":
version: 0.0.0-use.local
resolution: "@sm/nextjs@workspace:packages/nextjs"
dependencies:
"@apollo/client": ^3.10.8
"@aptos-labs/wallet-adapter-ant-design": ^2.6.2
Expand Down Expand Up @@ -2113,20 +2133,6 @@ __metadata:
languageName: unknown
linkType: soft

"@sinclair/typebox@npm:0.25.24":
version: 0.25.24
resolution: "@sinclair/typebox@npm:0.25.24"
checksum: 10219c58f40b8414c50b483b0550445e9710d4fe7b2c4dccb9b66533dd90ba8e024acc776026cebe81e87f06fa24b07fdd7bc30dd277eb9cc386ec50151a3026
languageName: node
linkType: hard

"@sindresorhus/is@npm:^4.0.0":
version: 4.6.0
resolution: "@sindresorhus/is@npm:4.6.0"
checksum: 83839f13da2c29d55c97abc3bc2c55b250d33a0447554997a85c539e058e57b8da092da396e252b11ec24a0279a0bed1f537fa26302209327060643e327f81d2
languageName: node
linkType: hard

"@socket.io/component-emitter@npm:~3.1.0":
version: 3.1.0
resolution: "@socket.io/component-emitter@npm:3.1.0"
Expand Down

0 comments on commit a2f2234

Please sign in to comment.