Questions tagged [anchor-program]

The tag has no usage guidance.

Filter by
Sorted by
Tagged with
5 votes
1 answer
147 views

how to deploy a program using clients like @solana/web3.js, @project-serum/anchor

I dont want to deploy a program using cli or solana playground ide I want to deploy a program using clients packages of solana/web3.js, @project-serum/anchor, or any other packages can anyone please ...
Mojo's user avatar
  • 149
3 votes
1 answer
343 views

Can I change the program to use different programID?

I need to deploy my current program with different programId. It's already deployed to the devnet. But I need to deploy it again to devnet using different programId. Is that possible?. Thanks.
Kaveen Laksitha's user avatar
7 votes
2 answers
1k views

how to convert pubkey to accountinfo?

I'm writing a program where I'm fetching the program_address (as below) and now I want to convert the publicKey to AccountInfo and use it to do token transfer CPI. let (asset, bump_seed) = Pubkey::...
Gajesh S Naik's user avatar
1 vote
1 answer
62 views

Defining composite fields using Anchor Accounts structs from other crates

Consider an anchor workspace set up like so: programs/a/lib.rs programs/b/lib.rs programs/c/lib.rs common/lib.rs With accounts struct in the common crate: // common/lib.rs #[derive(Accounts)] pub ...
HelmetFace's user avatar
  • 1,677