Skip to content
Merged
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
1 change: 1 addition & 0 deletions mover/Sucbusman/code/task02/faucet_coin/.gitignore
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
build/*
62 changes: 62 additions & 0 deletions mover/Sucbusman/code/task02/faucet_coin/Move.lock
Original file line number Diff line number Diff line change
@@ -0,0 +1,62 @@
# @generated by Move, please check-in and do not edit manually.

[move]
version = 3
manifest_digest = "434FF74A9C33093F72ED1C50C686D86010665583F34431C719ED4ECAA5A5AD17"
deps_digest = "F9B494B64F0615AED0E98FC12A85B85ECD2BC5185C22D30E7F67786BB52E507C"
dependencies = [
{ id = "Bridge", name = "Bridge" },
{ id = "MoveStdlib", name = "MoveStdlib" },
{ id = "Sui", name = "Sui" },
{ id = "SuiSystem", name = "SuiSystem" },
]

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

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

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

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

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

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

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

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

[env]

[env.testnet]
chain-id = "4c78adac"
original-published-id = "0x3449c34c857d1436e5cffb95c4fa48b20b49b17d14961a14a8375b6a0ec5827a"
latest-published-id = "0x3449c34c857d1436e5cffb95c4fa48b20b49b17d14961a14a8375b6a0ec5827a"
published-version = "1"

[env.mainnet]
chain-id = "35834a8a"
original-published-id = "0x92c4d6224e9638b7aeae3077c4a253a157635cacc7a22db8ab67ea7e727c71c3"
latest-published-id = "0x92c4d6224e9638b7aeae3077c4a253a157635cacc7a22db8ab67ea7e727c71c3"
published-version = "1"
36 changes: 36 additions & 0 deletions mover/Sucbusman/code/task02/faucet_coin/Move.toml
Original file line number Diff line number Diff line change
@@ -0,0 +1,36 @@
[package]
name = "faucet_coin"
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]

# 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_coin = "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"

2 changes: 2 additions & 0 deletions mover/Sucbusman/code/task02/faucet_coin/sources/faucet.sh
Original file line number Diff line number Diff line change
@@ -0,0 +1,2 @@
#!/bin/bash
sui client call --package 0x2 --module coin --function mint_and_transfer --type-args 0x92c4d6224e9638b7aeae3077c4a253a157635cacc7a22db8ab67ea7e727c71c3::faucet_coin::FAUCET_COIN --args 0x45ef74abb23ec6ea5cdcc1bf5fc2d51dad0f35a0e4a278917366ebb39947fb40 10000000 0xe1737aebeba598a19136f89859b9a4cd9b50e9ecd74e4fb1893033f78187d3b8
12 changes: 12 additions & 0 deletions mover/Sucbusman/code/task02/faucet_coin/sources/faucet_coin.move
Original file line number Diff line number Diff line change
@@ -0,0 +1,12 @@
module faucet_coin::faucet_coin;
use sui::coin::create_currency;
use sui::transfer::{public_freeze_object,public_share_object};

public struct FAUCET_COIN has drop{}

fun init(c:FAUCET_COIN, ctx:&mut TxContext){
let (treasury,meta) = create_currency(c, 8, b"FHKD", b"Free Hong Kong Dollar", b"Test description", option::none(), ctx);
public_freeze_object(meta);
public_share_object(treasury);
}

Original file line number Diff line number Diff line change
@@ -0,0 +1,18 @@
/*
#[test_only]
module faucet_coin::faucet_coin_tests;
// uncomment this line to import the module
// use faucet_coin::faucet_coin;

const ENotImplemented: u64 = 0;

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

#[test, expected_failure(abort_code = ::faucet_coin::faucet_coin_tests::ENotImplemented)]
fun test_faucet_coin_fail() {
abort ENotImplemented
}
*/
1 change: 1 addition & 0 deletions mover/Sucbusman/code/task02/my_coin/.gitignore
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
build/*
62 changes: 62 additions & 0 deletions mover/Sucbusman/code/task02/my_coin/Move.lock
Original file line number Diff line number Diff line change
@@ -0,0 +1,62 @@
# @generated by Move, please check-in and do not edit manually.

[move]
version = 3
manifest_digest = "6A9EA0C7B2B1375E2F2C241BAE6B953FCD018775846DEDBA226EFBFB2FB6E003"
deps_digest = "F9B494B64F0615AED0E98FC12A85B85ECD2BC5185C22D30E7F67786BB52E507C"
dependencies = [
{ id = "Bridge", name = "Bridge" },
{ id = "MoveStdlib", name = "MoveStdlib" },
{ id = "Sui", name = "Sui" },
{ id = "SuiSystem", name = "SuiSystem" },
]

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

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

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

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

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

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

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

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

[env]

[env.testnet]
chain-id = "4c78adac"
original-published-id = "0x67224c61835d34d06c44e170190dbfe1d6e1053f1add0d71b87a262be5ed0a1c"
latest-published-id = "0x67224c61835d34d06c44e170190dbfe1d6e1053f1add0d71b87a262be5ed0a1c"
published-version = "1"

[env.mainnet]
chain-id = "35834a8a"
original-published-id = "0x59a1d86e148649d9cc99e7b051c2b2a75d4c38c72091608d4f9c4a751ce4f327"
latest-published-id = "0x59a1d86e148649d9cc99e7b051c2b2a75d4c38c72091608d4f9c4a751ce4f327"
published-version = "1"
36 changes: 36 additions & 0 deletions mover/Sucbusman/code/task02/my_coin/Move.toml
Original file line number Diff line number Diff line change
@@ -0,0 +1,36 @@
[package]
name = "my_coin"
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]

# 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]
my_coin = "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"

2 changes: 2 additions & 0 deletions mover/Sucbusman/code/task02/my_coin/sources/mint.sh
Original file line number Diff line number Diff line change
@@ -0,0 +1,2 @@
#!/bin/bash
sui client call --package 0x2 --module coin --function mint_and_transfer --type-args 0x59a1d86e148649d9cc99e7b051c2b2a75d4c38c72091608d4f9c4a751ce4f327::my_coin::MY_COIN --args 0x7be53a569bbb1650b4785d8ec6cc7ab02b815d4ba8c476a82b3caf2f27792da8 10000000 0x9b45b2c6a3869f0b4c6128847b421fafc1325538e42741ce10291df8bf997b72
12 changes: 12 additions & 0 deletions mover/Sucbusman/code/task02/my_coin/sources/my_coin.move
Original file line number Diff line number Diff line change
@@ -0,0 +1,12 @@
module my_coin::my_coin;
use sui::coin::create_currency;
use sui::transfer::{public_freeze_object,public_transfer};

public struct MY_COIN has drop{}

fun init(c:MY_COIN, ctx:&mut TxContext){
let (treasury,meta) = create_currency(c, 8, b"HKD", b"Hong Kong Dollar", b"Test description", option::none(), ctx);
public_freeze_object(meta);
public_transfer(treasury,ctx.sender());
}

18 changes: 18 additions & 0 deletions mover/Sucbusman/code/task02/my_coin/tests/my_coin_tests.move
Original file line number Diff line number Diff line change
@@ -0,0 +1,18 @@
/*
#[test_only]
module my_coin::my_coin_tests;
// uncomment this line to import the module
// use my_coin::my_coin;

const ENotImplemented: u64 = 0;

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

#[test, expected_failure(abort_code = ::my_coin::my_coin_tests::ENotImplemented)]
fun test_my_coin_fail() {
abort ENotImplemented
}
*/
1 change: 1 addition & 0 deletions mover/Sucbusman/code/task03/my_nft/.gitignore
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
build/*
68 changes: 68 additions & 0 deletions mover/Sucbusman/code/task03/my_nft/Move.lock
Original file line number Diff line number Diff line change
@@ -0,0 +1,68 @@
# @generated by Move, please check-in and do not edit manually.

[move]
version = 3
manifest_digest = "198F8D2C6C9494D80E47F5DA94532E105BCDFC1DFC3B4C6E03849FBF9803D9BE"
deps_digest = "F9B494B64F0615AED0E98FC12A85B85ECD2BC5185C22D30E7F67786BB52E507C"
dependencies = [
{ id = "Bridge", name = "Bridge" },
{ id = "MoveStdlib", name = "MoveStdlib" },
{ id = "Sui", name = "Sui" },
{ id = "SuiSystem", name = "SuiSystem" },
]

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

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

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

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

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

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

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

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

[env]

[env.local]
chain-id = "b2791071"
original-published-id = "0x471ffb842d91567c2da27fa371027f5f4fbb97814696ae2568084a6193d67e50"
latest-published-id = "0x471ffb842d91567c2da27fa371027f5f4fbb97814696ae2568084a6193d67e50"
published-version = "1"

[env.testnet]
chain-id = "4c78adac"
original-published-id = "0x20c220a003214fa03d5569766bc081b50746884b530e77bd8830eda234f534d9"
latest-published-id = "0x20c220a003214fa03d5569766bc081b50746884b530e77bd8830eda234f534d9"
published-version = "1"

[env.mainnet]
chain-id = "35834a8a"
original-published-id = "0xe847bdadab781e87f566ecffae050c26772f6ceb1976f4dbdc6020c2351e1ea7"
latest-published-id = "0xe847bdadab781e87f566ecffae050c26772f6ceb1976f4dbdc6020c2351e1ea7"
published-version = "1"
36 changes: 36 additions & 0 deletions mover/Sucbusman/code/task03/my_nft/Move.toml
Original file line number Diff line number Diff line change
@@ -0,0 +1,36 @@
[package]
name = "my_nft"
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]

# 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]
my_nft = "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