From c9b812aca10d61490630c0381f622308f5bda41e Mon Sep 17 00:00:00 2001 From: cfanbo Date: Wed, 8 Jan 2025 16:02:00 +0800 Subject: [PATCH 1/3] remove duplicate assignments --- basics/favorites/native/tests/test.ts | 4 ---- 1 file changed, 4 deletions(-) diff --git a/basics/favorites/native/tests/test.ts b/basics/favorites/native/tests/test.ts index bb0d33b5c..29f617688 100644 --- a/basics/favorites/native/tests/test.ts +++ b/basics/favorites/native/tests/test.ts @@ -100,7 +100,6 @@ test('Set the favorite pda and cross-check the updated data', async () => { tx.feePayer = payer.publicKey; tx.recentBlockhash = blockhash tx.sign(payer) - tx.recentBlockhash = blockhash; await client.processTransaction(tx); const account = await client.getAccount(favoritesPda); @@ -132,7 +131,6 @@ test('Set the favorite pda and cross-check the updated data', async () => { tx.feePayer = payer.publicKey; tx.recentBlockhash = blockhash tx.sign(payer) - tx.recentBlockhash = blockhash; try { await client.processTransaction(tx) console.error("Expected the test to fail") @@ -161,7 +159,6 @@ test('Set the favorite pda and cross-check the updated data', async () => { tx1.feePayer = payer.publicKey; tx1.recentBlockhash = blockhash tx1.sign(payer) - tx1.recentBlockhash = blockhash; await client.processTransaction(tx1) @@ -180,7 +177,6 @@ test('Set the favorite pda and cross-check the updated data', async () => { tx.feePayer = payer.publicKey; tx.recentBlockhash = blockhash tx.sign(payer) - tx.recentBlockhash = blockhash; await client.processTransaction(tx); }) }) \ No newline at end of file From 4ca817219d47c67788ab20cf8c3cd7c27e24f67d Mon Sep 17 00:00:00 2001 From: cfanbo Date: Fri, 10 Jan 2025 13:05:49 +0800 Subject: [PATCH 2/3] fix: basics/close-account/native/cicd.sh --- basics/close-account/native/cicd.sh | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/basics/close-account/native/cicd.sh b/basics/close-account/native/cicd.sh index 0903cf896..3b47fccef 100644 --- a/basics/close-account/native/cicd.sh +++ b/basics/close-account/native/cicd.sh @@ -4,5 +4,5 @@ # It also serves as a reference for the commands used for building & deploying Solana programs. # Run this bad boy with "bash cicd.sh" or "./cicd.sh" -cargo build-sbf --manifest-path=./program/Cargo.toml --bpf-out-dir=./program/target/so -solana program deploy ./program/target/so/program.so +cargo build-sbf --manifest-path=./program/Cargo.toml --sbf-out-dir=./program/target/so +solana program deploy ./program/target/so/close_account_native_program.so From 95a96681b356dd7a686d69511650acb2b0255229 Mon Sep 17 00:00:00 2001 From: cfanbo Date: Fri, 10 Jan 2025 13:39:57 +0800 Subject: [PATCH 3/3] fix: cicd.sh --- basics/account-data/native/cicd.sh | 4 ++-- basics/checking-accounts/native/cicd.sh | 4 ++-- basics/close-account/steel/cicd.sh | 2 +- basics/create-account/native/cicd.sh | 4 ++-- basics/favorites/native/cicd.sh | 4 ++-- basics/hello-solana/native/cicd.sh | 4 ++-- basics/pda-rent-payer/native/cicd.sh | 4 ++-- basics/processing-instructions/native/cicd.sh | 4 ++-- basics/program-derived-addresses/native/cicd.sh | 4 ++-- basics/realloc/native/cicd.sh | 4 ++-- basics/rent/native/cicd.sh | 2 +- basics/repository-layout/native/cicd.sh | 4 ++-- basics/transfer-sol/native/cicd.sh | 4 ++-- basics/transfer-sol/steel/cicd.sh | 2 +- 14 files changed, 25 insertions(+), 25 deletions(-) diff --git a/basics/account-data/native/cicd.sh b/basics/account-data/native/cicd.sh index 0903cf896..840ecaac2 100644 --- a/basics/account-data/native/cicd.sh +++ b/basics/account-data/native/cicd.sh @@ -4,5 +4,5 @@ # It also serves as a reference for the commands used for building & deploying Solana programs. # Run this bad boy with "bash cicd.sh" or "./cicd.sh" -cargo build-sbf --manifest-path=./program/Cargo.toml --bpf-out-dir=./program/target/so -solana program deploy ./program/target/so/program.so +cargo build-sbf --manifest-path=./program/Cargo.toml --sbf-out-dir=./program/target/so +solana program deploy ./program/target/so/account_data_program.so diff --git a/basics/checking-accounts/native/cicd.sh b/basics/checking-accounts/native/cicd.sh index 0903cf896..00d7cc260 100644 --- a/basics/checking-accounts/native/cicd.sh +++ b/basics/checking-accounts/native/cicd.sh @@ -4,5 +4,5 @@ # It also serves as a reference for the commands used for building & deploying Solana programs. # Run this bad boy with "bash cicd.sh" or "./cicd.sh" -cargo build-sbf --manifest-path=./program/Cargo.toml --bpf-out-dir=./program/target/so -solana program deploy ./program/target/so/program.so +cargo build-sbf --manifest-path=./program/Cargo.toml --sbf-out-dir=./program/target/so +solana program deploy ./program/target/so/checking_accounts_program.so diff --git a/basics/close-account/steel/cicd.sh b/basics/close-account/steel/cicd.sh index 0903cf896..b2407c75f 100644 --- a/basics/close-account/steel/cicd.sh +++ b/basics/close-account/steel/cicd.sh @@ -4,5 +4,5 @@ # It also serves as a reference for the commands used for building & deploying Solana programs. # Run this bad boy with "bash cicd.sh" or "./cicd.sh" -cargo build-sbf --manifest-path=./program/Cargo.toml --bpf-out-dir=./program/target/so +cargo build-sbf --manifest-path=./program/Cargo.toml --sbf-out-dir=./program/target/so solana program deploy ./program/target/so/program.so diff --git a/basics/create-account/native/cicd.sh b/basics/create-account/native/cicd.sh index 0903cf896..9d8000ab4 100644 --- a/basics/create-account/native/cicd.sh +++ b/basics/create-account/native/cicd.sh @@ -4,5 +4,5 @@ # It also serves as a reference for the commands used for building & deploying Solana programs. # Run this bad boy with "bash cicd.sh" or "./cicd.sh" -cargo build-sbf --manifest-path=./program/Cargo.toml --bpf-out-dir=./program/target/so -solana program deploy ./program/target/so/program.so +cargo build-sbf --manifest-path=./program/Cargo.toml --sbf-out-dir=./program/target/so +solana program deploy ./program/target/so/create_account_program.so diff --git a/basics/favorites/native/cicd.sh b/basics/favorites/native/cicd.sh index 0903cf896..2c0b33029 100644 --- a/basics/favorites/native/cicd.sh +++ b/basics/favorites/native/cicd.sh @@ -4,5 +4,5 @@ # It also serves as a reference for the commands used for building & deploying Solana programs. # Run this bad boy with "bash cicd.sh" or "./cicd.sh" -cargo build-sbf --manifest-path=./program/Cargo.toml --bpf-out-dir=./program/target/so -solana program deploy ./program/target/so/program.so +cargo build-sbf --manifest-path=./program/Cargo.toml --sbf-out-dir=./program/target/so +solana program deploy ./program/target/so/favorites_native.so diff --git a/basics/hello-solana/native/cicd.sh b/basics/hello-solana/native/cicd.sh index 0903cf896..00a1fc130 100644 --- a/basics/hello-solana/native/cicd.sh +++ b/basics/hello-solana/native/cicd.sh @@ -4,5 +4,5 @@ # It also serves as a reference for the commands used for building & deploying Solana programs. # Run this bad boy with "bash cicd.sh" or "./cicd.sh" -cargo build-sbf --manifest-path=./program/Cargo.toml --bpf-out-dir=./program/target/so -solana program deploy ./program/target/so/program.so +cargo build-sbf --manifest-path=./program/Cargo.toml --sbf-out-dir=./program/target/so +solana program deploy ./program/target/so/hello_solana_program.so diff --git a/basics/pda-rent-payer/native/cicd.sh b/basics/pda-rent-payer/native/cicd.sh index 0903cf896..dce8d4f2c 100644 --- a/basics/pda-rent-payer/native/cicd.sh +++ b/basics/pda-rent-payer/native/cicd.sh @@ -4,5 +4,5 @@ # It also serves as a reference for the commands used for building & deploying Solana programs. # Run this bad boy with "bash cicd.sh" or "./cicd.sh" -cargo build-sbf --manifest-path=./program/Cargo.toml --bpf-out-dir=./program/target/so -solana program deploy ./program/target/so/program.so +cargo build-sbf --manifest-path=./program/Cargo.toml --sbf-out-dir=./program/target/so +solana program deploy ./program/target/so/pda_rent_payer_program.so diff --git a/basics/processing-instructions/native/cicd.sh b/basics/processing-instructions/native/cicd.sh index 0903cf896..3741bccb0 100644 --- a/basics/processing-instructions/native/cicd.sh +++ b/basics/processing-instructions/native/cicd.sh @@ -4,5 +4,5 @@ # It also serves as a reference for the commands used for building & deploying Solana programs. # Run this bad boy with "bash cicd.sh" or "./cicd.sh" -cargo build-sbf --manifest-path=./program/Cargo.toml --bpf-out-dir=./program/target/so -solana program deploy ./program/target/so/program.so +cargo build-sbf --manifest-path=./program/Cargo.toml --sbf-out-dir=./program/target/so +solana program deploy ./program/target/so/processing_instructions_program.so diff --git a/basics/program-derived-addresses/native/cicd.sh b/basics/program-derived-addresses/native/cicd.sh index 0903cf896..5667bd7ec 100644 --- a/basics/program-derived-addresses/native/cicd.sh +++ b/basics/program-derived-addresses/native/cicd.sh @@ -4,5 +4,5 @@ # It also serves as a reference for the commands used for building & deploying Solana programs. # Run this bad boy with "bash cicd.sh" or "./cicd.sh" -cargo build-sbf --manifest-path=./program/Cargo.toml --bpf-out-dir=./program/target/so -solana program deploy ./program/target/so/program.so +cargo build-sbf --manifest-path=./program/Cargo.toml --sbf-out-dir=./program/target/so +solana program deploy ./program/target/so/program_derived_addresses_program.so diff --git a/basics/realloc/native/cicd.sh b/basics/realloc/native/cicd.sh index 0903cf896..b44f1bda8 100644 --- a/basics/realloc/native/cicd.sh +++ b/basics/realloc/native/cicd.sh @@ -4,5 +4,5 @@ # It also serves as a reference for the commands used for building & deploying Solana programs. # Run this bad boy with "bash cicd.sh" or "./cicd.sh" -cargo build-sbf --manifest-path=./program/Cargo.toml --bpf-out-dir=./program/target/so -solana program deploy ./program/target/so/program.so +cargo build-sbf --manifest-path=./program/Cargo.toml --sbf-out-dir=./program/target/so +solana program deploy ./program/target/so/realloc_program.so diff --git a/basics/rent/native/cicd.sh b/basics/rent/native/cicd.sh index 0903cf896..b2407c75f 100644 --- a/basics/rent/native/cicd.sh +++ b/basics/rent/native/cicd.sh @@ -4,5 +4,5 @@ # It also serves as a reference for the commands used for building & deploying Solana programs. # Run this bad boy with "bash cicd.sh" or "./cicd.sh" -cargo build-sbf --manifest-path=./program/Cargo.toml --bpf-out-dir=./program/target/so +cargo build-sbf --manifest-path=./program/Cargo.toml --sbf-out-dir=./program/target/so solana program deploy ./program/target/so/program.so diff --git a/basics/repository-layout/native/cicd.sh b/basics/repository-layout/native/cicd.sh index 0903cf896..7878a88f8 100644 --- a/basics/repository-layout/native/cicd.sh +++ b/basics/repository-layout/native/cicd.sh @@ -4,5 +4,5 @@ # It also serves as a reference for the commands used for building & deploying Solana programs. # Run this bad boy with "bash cicd.sh" or "./cicd.sh" -cargo build-sbf --manifest-path=./program/Cargo.toml --bpf-out-dir=./program/target/so -solana program deploy ./program/target/so/program.so +cargo build-sbf --manifest-path=./program/Cargo.toml --sbf-out-dir=./program/target/so +solana program deploy ./program/target/so/repository_layout_program.so diff --git a/basics/transfer-sol/native/cicd.sh b/basics/transfer-sol/native/cicd.sh index 0903cf896..e97d5f483 100644 --- a/basics/transfer-sol/native/cicd.sh +++ b/basics/transfer-sol/native/cicd.sh @@ -4,5 +4,5 @@ # It also serves as a reference for the commands used for building & deploying Solana programs. # Run this bad boy with "bash cicd.sh" or "./cicd.sh" -cargo build-sbf --manifest-path=./program/Cargo.toml --bpf-out-dir=./program/target/so -solana program deploy ./program/target/so/program.so +cargo build-sbf --manifest-path=./program/Cargo.toml --sbf-out-dir=./program/target/so +solana program deploy ./program/target/so/transfer_sol_program.so diff --git a/basics/transfer-sol/steel/cicd.sh b/basics/transfer-sol/steel/cicd.sh index d5960d7b7..54a0b1ffc 100644 --- a/basics/transfer-sol/steel/cicd.sh +++ b/basics/transfer-sol/steel/cicd.sh @@ -4,5 +4,5 @@ # It also serves as a reference for the commands used for building & deploying Solana programs. # Run this bad boy with "bash cicd.sh" or "./cicd.sh" -cargo build-sbf --manifest-path=./program/Cargo.toml --bpf-out-dir=./program/target/so +cargo build-sbf --manifest-path=./program/Cargo.toml --sbf-out-dir=./program/target/so solana program deploy ./program/target/so/program.so \ No newline at end of file