Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
46 changes: 46 additions & 0 deletions mover/phuclam/README.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,46 @@
## Basic Information
- Sui Wallet Address: `0x83c1cf7f43e1796c8a1d36faec580d72d7d91d91fcff4b9acde7ff9179cb7202`
> First-time participants must complete the registration of the wallet address through the first task to have it merged. You should use this address for subsequent tasks. We will also use this address to credit the learning rewards.
- Github: `PhucLam202`[https://github.com/PhucLam202]

## Personal Introduction
- Work Experience: `1 years`
- Tech Stack: `Rust` `Typescript` `Nodejs` , etc.
> Important: Please take your personal introduction seriously.
- Half year of experience in web2 back-end development,got a litter bit of experience in blockchain research, particularly interested in Move and rust, aiming to use Move as an entry point into blockchain.
- Contact: telegram `AlexLamZ9`[https://t.me/AlexLamZ9]

## Tasks

### 01 hello move
- [x] `Sui CLI Version`: 1.38.3
- [x] `Sui Wallet Screenshot`: Link to image uploaded to `images` folder [link](./images/task1_wallet_address.png)
- [x] `Package ID`: 0xc90e0bc5dd0dda8637ea78e52d940b179f51e4893a285d474b626d4d9507eafd
- [x] `Package ID's Screenshot from Explorer: Link to image uploaded to `images` folder [link](./images/task1_packageId.png)

### 02 move coin
- [x] `My Coin Package ID`: 0x6494ddac93e81801903de414722b3641efa61dc83859603e67e6d2bfa833e8e4
- [x] `Faucet Coin Package ID`:0xbb6414aea77149258beb7b490b9bdc74f2827e14304a19a726da8cc8bb3c5f25
- [x] `Transfer My Coin hash`: CRD7KUBMLXWCTZ3LcAHgLXCCAs1FBCUbfSphpeDDS54z
- [x] `Faucet Coin address 1 mint hash`: 0xbb6414aea77149258beb7b490b9bdc74f2827e14304a19a726da8cc8bb3c5f25
- [x] `Faucet Coin address 2 mint hash`: 0xbb6414aea77149258beb7b490b9bdc74f2827e14304a19a726da8cc8bb3c5f25

### 03 move nft
- [x] `NFT Package ID`:0xcb779f2f2b5887e6d926369d8244e02273b96de8968784e9c2d9f62a931ee4ef
- [x] `NFT Object ID`: 0xda514abcb71ec99f27a635059d318886747fae3fb4466f2d9c3b4ad47429ca56
- [x] `Transfer NFT hash`: 4RjtJHXvHPcz8JVx7uEJq1DHqcBDYp8QeXmXAML1x7aa
- [x] `NFT's Screenshot from Explorer`: Link to image uploaded to `images` folder [link](./images/task3_NFT.png)

### 04 move game
- [x] `Game Package ID`: 0x375e73614b265a38abbc8797c2112f6f46554c4f91e46a38cc6a52ea4833bb05
- [x] `Deposit Coin Hash`: GHLgW4Ax1zSDUZ8WZNLVjqkMWExwGAj34axiPywLGt6S
- [x] `Withdraw Coin Hash`: HDbkgFmX2KgMMReWVLXo23VAAnb6BBTbkyv2RDRFLytn
- [x] `Play Game Hash`: DPnN4RgurAfVn8HaqEFGpRgmG1aPPhTZXGw8MVaJQtGY

### 05 move swap
- [ ] Swap Package ID:
- [ ] Call Swap Coin A -> Coin B hash:
- [ ] Call Swap Coin B -> Coin A hash:

### 06 dapp-kit SDK PTB
- [ ] Save Hash:
40 changes: 40 additions & 0 deletions mover/phuclam/code/task_1_hello_word/Move.lock
Original file line number Diff line number Diff line change
@@ -0,0 +1,40 @@
# @generated by Move, please check-in and do not edit manually.

[move]
version = 3
manifest_digest = "C5320A3324AE6D30249ECB86B243B0ECAE981F0FA7468EA5FF67D4090E264AAD"
deps_digest = "F8BBB0CCB2491CA29A3DF03D6F92277A4F3574266507ACD77214D37ECA3F3082"
dependencies = [
{ id = "Sui", name = "Sui" },
]

[[move.package]]
id = "MoveStdlib"
source = { git = "https://github.com/MystenLabs/sui.git", rev = "framework/testnet", subdir = "crates/sui-framework/packages/move-stdlib" }

[[move.package]]
id = "Sui"
source = { git = "https://github.com/MystenLabs/sui.git", rev = "framework/testnet", subdir = "crates/sui-framework/packages/sui-framework" }

dependencies = [
{ id = "MoveStdlib", name = "MoveStdlib" },
]

[move.toolchain-version]
compiler-version = "1.38.3"
edition = "2024.beta"
flavor = "sui"

[env]

[env.devnet]
chain-id = "663dca31"
original-published-id = "0x77e1400464dd231b612a6b9d480a90ad794fd3259f721164f63244c051c809e0"
latest-published-id = "0x77e1400464dd231b612a6b9d480a90ad794fd3259f721164f63244c051c809e0"
published-version = "1"

[env.testnet]
chain-id = "4c78adac"
original-published-id = "0xc90e0bc5dd0dda8637ea78e52d940b179f51e4893a285d474b626d4d9507eafd"
latest-published-id = "0xc90e0bc5dd0dda8637ea78e52d940b179f51e4893a285d474b626d4d9507eafd"
published-version = "1"
37 changes: 37 additions & 0 deletions mover/phuclam/code/task_1_hello_word/Move.toml
Original file line number Diff line number Diff line change
@@ -0,0 +1,37 @@
[package]
name = "task_1_hello_word"
edition = "2024.beta" # edition = "legacy" to use legacy (pre-2024) Move
# license = "" # e.g., "MIT", "GPL", "Apache 2.0"
# authors = ["..."] # e.g., ["Joe Smith (joesmith@noemail.com)", "John Snow (johnsnow@noemail.com)"]

[dependencies]
Sui = { git = "https://github.com/MystenLabs/sui.git", subdir = "crates/sui-framework/packages/sui-framework", rev = "framework/testnet" }

# For remote import, use the `{ git = "...", subdir = "...", rev = "..." }`.
# Revision can be a branch, a tag, and a commit hash.
# MyRemotePackage = { git = "https://some.remote/host.git", subdir = "remote/path", rev = "main" }

# For local dependencies use `local = path`. Path is relative to the package root
# Local = { local = "../path/to" }

# To resolve a version conflict and force a specific version for dependency
# override use `override = true`
# Override = { local = "../conflicting/version", override = true }

[addresses]
task_1_hello_word = "0x0"

# Named addresses will be accessible in Move as `@name`. They're also exported:
# for example, `std = "0x1"` is exported by the Standard Library.
# alice = "0xA11CE"

[dev-dependencies]
# The dev-dependencies section allows overriding dependencies for `--test` and
# `--dev` modes. You can introduce test-only dependencies here.
# Local = { local = "../path/to/dev-build" }

[dev-addresses]
# The dev-addresses section allows overwriting named addresses for the `--test`
# and `--dev` modes.
# alice = "0xB0B"

Original file line number Diff line number Diff line change
@@ -0,0 +1,21 @@
/*
/// Module: task_1_hello_word
module task_1_hello_word::task_1_hello_word;
*/
module task_1_hello_word::task_1_hello_word{

use std::string;

public struct HelloWordObj has key, store{
id:UID,
text: string::String,
}
#[lint_allow(self_transfer)]
public entry fun hello_word(ctx: &mut TxContext){
let object = HelloWordObj{
id: object::new(ctx),
text: string::utf8(b"Hello, World!"),
};
transfer::public_transfer(object,tx_context::sender(ctx));
}
}
Original file line number Diff line number Diff line change
@@ -0,0 +1,18 @@
/*
#[test_only]
module task_1_hello_word::task_1_hello_word_tests;
// uncomment this line to import the module
// use task_1_hello_word::task_1_hello_word;

const ENotImplemented: u64 = 0;

#[test]
fun test_task_1_hello_word() {
// pass
}

#[test, expected_failure(abort_code = ::task_1_hello_word::task_1_hello_word_tests::ENotImplemented)]
fun test_task_1_hello_word_fail() {
abort ENotImplemented
}
*/
34 changes: 34 additions & 0 deletions mover/phuclam/code/task_2_move_coin/faucet_token/Move.lock
Original file line number Diff line number Diff line change
@@ -0,0 +1,34 @@
# @generated by Move, please check-in and do not edit manually.

[move]
version = 3
manifest_digest = "BA7BB5EE93CA7B3D2E7B1C2456BB0DD2B68B215A705269343E29E17FE9D195F0"
deps_digest = "F8BBB0CCB2491CA29A3DF03D6F92277A4F3574266507ACD77214D37ECA3F3082"
dependencies = [
{ id = "Sui", name = "Sui" },
]

[[move.package]]
id = "MoveStdlib"
source = { git = "https://github.com/MystenLabs/sui.git", rev = "framework/testnet", subdir = "crates/sui-framework/packages/move-stdlib" }

[[move.package]]
id = "Sui"
source = { git = "https://github.com/MystenLabs/sui.git", rev = "framework/testnet", subdir = "crates/sui-framework/packages/sui-framework" }

dependencies = [
{ id = "MoveStdlib", name = "MoveStdlib" },
]

[move.toolchain-version]
compiler-version = "1.38.3"
edition = "2024.beta"
flavor = "sui"

[env]

[env.testnet]
chain-id = "4c78adac"
original-published-id = "0xbbffb7150d83e1f6adc1109efbd1db064dfc0313516d9146423299957db5ac37"
latest-published-id = "0xbbffb7150d83e1f6adc1109efbd1db064dfc0313516d9146423299957db5ac37"
published-version = "1"
37 changes: 37 additions & 0 deletions mover/phuclam/code/task_2_move_coin/faucet_token/Move.toml
Original file line number Diff line number Diff line change
@@ -0,0 +1,37 @@
[package]
name = "faucet_token"
edition = "2024.beta" # edition = "legacy" to use legacy (pre-2024) Move
# license = "" # e.g., "MIT", "GPL", "Apache 2.0"
# authors = ["..."] # e.g., ["Joe Smith (joesmith@noemail.com)", "John Snow (johnsnow@noemail.com)"]

[dependencies]
Sui = { git = "https://github.com/MystenLabs/sui.git", subdir = "crates/sui-framework/packages/sui-framework", rev = "framework/testnet" }

# For remote import, use the `{ git = "...", subdir = "...", rev = "..." }`.
# Revision can be a branch, a tag, and a commit hash.
# MyRemotePackage = { git = "https://some.remote/host.git", subdir = "remote/path", rev = "main" }

# For local dependencies use `local = path`. Path is relative to the package root
# Local = { local = "../path/to" }

# To resolve a version conflict and force a specific version for dependency
# override use `override = true`
# Override = { local = "../conflicting/version", override = true }

[addresses]
faucet_token = "0x0"

# Named addresses will be accessible in Move as `@name`. They're also exported:
# for example, `std = "0x1"` is exported by the Standard Library.
# alice = "0xA11CE"

[dev-dependencies]
# The dev-dependencies section allows overriding dependencies for `--test` and
# `--dev` modes. You can introduce test-only dependencies here.
# Local = { local = "../path/to/dev-build" }

[dev-addresses]
# The dev-addresses section allows overwriting named addresses for the `--test`
# and `--dev` modes.
# alice = "0xB0B"

Original file line number Diff line number Diff line change
@@ -0,0 +1,34 @@
module faucet_token::faucet_token {
use sui::coin::{Self, create_currency, TreasuryCap};
use sui::url::{Self};
use sui::transfer;
use sui::tx_context::{Self, TxContext, sender};
use std::option::{Self, some};


// Define the one-time witness struct
public struct FAUCET_TOKEN has drop {}

fun init(witness: FAUCET_TOKEN, ctx: &mut TxContext) {
let (treasury, metadata) = create_currency(
witness,
8,
b"FAUCET_TOKEN",
b"PhucLam Coin",
b"This is PhucLam's test coin on Sui",
some(url::new_unsafe_from_bytes(b"https://drive.google.com/file/d/11dgb-60066S4IIKgI5tDR4RKueZ-5vWZ/view?usp=sharing")), // icon url

ctx
);
transfer::public_freeze_object(metadata);
transfer::public_share_object(treasury);
}

public entry fun mint(
treasury: &mut TreasuryCap<FAUCET_TOKEN>,
ctx: &mut TxContext
) {
let mint_coin = coin::mint(treasury, 1000000000000000000, ctx);
transfer::public_transfer(mint_coin, ctx.sender());
}
}
Original file line number Diff line number Diff line change
@@ -0,0 +1,18 @@
/*
#[test_only]
module phuclam_faucet_token::phuclam_faucet_token_tests;
// uncomment this line to import the module
// use phuclam_faucet_token::phuclam_faucet_token;

const ENotImplemented: u64 = 0;

#[test]
fun test_phuclam_faucet_token() {
// pass
}

#[test, expected_failure(abort_code = ::phuclam_faucet_token::phuclam_faucet_token_tests::ENotImplemented)]
fun test_phuclam_faucet_token_fail() {
abort ENotImplemented
}
*/
34 changes: 34 additions & 0 deletions mover/phuclam/code/task_2_move_coin/token/Move.lock
Original file line number Diff line number Diff line change
@@ -0,0 +1,34 @@
# @generated by Move, please check-in and do not edit manually.

[move]
version = 3
manifest_digest = "5920A43A7D93AA3110BBCF36C427CB46D38596A6EDE0B17E5678C9851F7B401D"
deps_digest = "F8BBB0CCB2491CA29A3DF03D6F92277A4F3574266507ACD77214D37ECA3F3082"
dependencies = [
{ id = "Sui", name = "Sui" },
]

[[move.package]]
id = "MoveStdlib"
source = { git = "https://github.com/MystenLabs/sui.git", rev = "framework/testnet", subdir = "crates/sui-framework/packages/move-stdlib" }

[[move.package]]
id = "Sui"
source = { git = "https://github.com/MystenLabs/sui.git", rev = "framework/testnet", subdir = "crates/sui-framework/packages/sui-framework" }

dependencies = [
{ id = "MoveStdlib", name = "MoveStdlib" },
]

[move.toolchain-version]
compiler-version = "1.38.3"
edition = "2024.beta"
flavor = "sui"

[env]

[env.testnet]
chain-id = "4c78adac"
original-published-id = "0x6494ddac93e81801903de414722b3641efa61dc83859603e67e6d2bfa833e8e4"
latest-published-id = "0x6494ddac93e81801903de414722b3641efa61dc83859603e67e6d2bfa833e8e4"
published-version = "1"
37 changes: 37 additions & 0 deletions mover/phuclam/code/task_2_move_coin/token/Move.toml
Original file line number Diff line number Diff line change
@@ -0,0 +1,37 @@
[package]
name = "token"
edition = "2024.beta" # edition = "legacy" to use legacy (pre-2024) Move
# license = "" # e.g., "MIT", "GPL", "Apache 2.0"
# authors = ["..."] # e.g., ["Joe Smith (joesmith@noemail.com)", "John Snow (johnsnow@noemail.com)"]

[dependencies]
Sui = { git = "https://github.com/MystenLabs/sui.git", subdir = "crates/sui-framework/packages/sui-framework", rev = "framework/testnet" }

# For remote import, use the `{ git = "...", subdir = "...", rev = "..." }`.
# Revision can be a branch, a tag, and a commit hash.
# MyRemotePackage = { git = "https://some.remote/host.git", subdir = "remote/path", rev = "main" }

# For local dependencies use `local = path`. Path is relative to the package root
# Local = { local = "../path/to" }

# To resolve a version conflict and force a specific version for dependency
# override use `override = true`
# Override = { local = "../conflicting/version", override = true }

[addresses]
token = "0x0"

# Named addresses will be accessible in Move as `@name`. They're also exported:
# for example, `std = "0x1"` is exported by the Standard Library.
# alice = "0xA11CE"

[dev-dependencies]
# The dev-dependencies section allows overriding dependencies for `--test` and
# `--dev` modes. You can introduce test-only dependencies here.
# Local = { local = "../path/to/dev-build" }

[dev-addresses]
# The dev-addresses section allows overwriting named addresses for the `--test`
# and `--dev` modes.
# alice = "0xB0B"

Loading