John f2d93baee1 add resolver = "2" to fix compile warning 1 år sedan
..
migrations 3f59790e93 add seahorse transfer sol example 2 år sedan
programs 70efc6010f add idl-build to cargo.toml features 1 år sedan
programs_py 60e55ad6fd update function name to transfer with cpi 2 år sedan
tests 9112548d1a change spelling to mockReceiverAccount 2 år sedan
.gitignore 3f59790e93 add seahorse transfer sol example 2 år sedan
.prettierignore 3f59790e93 add seahorse transfer sol example 2 år sedan
Anchor.toml 3f59790e93 add seahorse transfer sol example 2 år sedan
Cargo.toml f2d93baee1 add resolver = "2" to fix compile warning 1 år sedan
README.md e39cdd2f57 add description for seahorse sol transfer 2 år sedan
package.json 3f59790e93 add seahorse transfer sol example 2 år sedan
tsconfig.json 3f59790e93 add seahorse transfer sol example 2 år sedan

README.md

Transfer SOL with Seahorse

Sadly, you can't send SOL(lamports) to another SystemAccount (Public Key) with Seahorse. That's why this Seahorse example looks a little different than the Anchor and Native ones. Here, we initialize a Mock PDA account where we send SOL to using transferLamports, which invokes a CPI with the System Program.