From 7a1a8d3d1e5853d67dbab1f166f31bbaaae482fd Mon Sep 17 00:00:00 2001 From: Chip Thien Date: Thu, 7 Dec 2023 16:14:49 -0600 Subject: [PATCH 1/3] Change urls and relative paths to absolute paths in hello-world-in-your-browser.md --- .../getstarted/hello-world-in-your-browser.md | 22 +++++++++---------- 1 file changed, 11 insertions(+), 11 deletions(-) diff --git a/content/guides/getstarted/hello-world-in-your-browser.md b/content/guides/getstarted/hello-world-in-your-browser.md index 8232e844a..40bcbe74e 100644 --- a/content/guides/getstarted/hello-world-in-your-browser.md +++ b/content/guides/getstarted/hello-world-in-your-browser.md @@ -69,7 +69,7 @@ icon and naming your project `hello_world`. ### Create a Playground wallet -Normally with [local development](./setup-local-development.md), you will need +Normally with [local development](/content/guides/getstarted/setup-local-development.md), you will need to create a file system wallet for use with the Solana CLI. But with the Solana Playground, you only need to click a few buttons to create a browser based wallet. @@ -86,7 +86,7 @@ click "**Continue**". After your Playground Wallet is created, you will notice the bottom of the window now states your wallet's address, your SOL balance, and the Solana cluster you are connected to (Devnet is usually the default/recommended, but a -"localhost" [test validator](./setup-local-development.md) is also acceptable). +"localhost" [test validator](/content/guides/getstarted/setup-local-development.md) is also acceptable). ## Create a Solana program @@ -113,7 +113,7 @@ use solana_program::{ Every Solana program must define an `entrypoint` that tells the Solana runtime where to start executing your on chain code. Your program's -[entrypoint](https://docs.solana.com/developing/on-chain-programs/developing-rust#program-entrypoint) +[entrypoint](/docs/developing/on-chain-programs/developing-rust.md#program-entrypoint) should provide a public function named `process_instruction`: ```rust @@ -139,7 +139,7 @@ Every on chain program should return the `Ok` tells the Solana runtime that your program executed successfully without errors. Our program above will simply -[log a message](https://docs.solana.com/developing/on-chain-programs/debugging#logging) +[log a message](/docs/developing/on-chain-programs/debugging.md#logging) of "_Hello, world!_" to the blockchain cluster, then gracefully exit with `Ok(())`. @@ -179,9 +179,9 @@ solana airdrop 2 ### Find your program id When executing a program using -[web3.js](https://docs.solana.com/developing/clients/javascript-reference) or +[web3.js](/docs/developing/clients/javascript-reference.md) or from -[another Solana program](https://docs.solana.com/developing/programming-model/calling-between-programs), +[another Solana program](/docs/developing/programming-model/calling-between-programs.md), you will need to provide the `program id` (aka public address of your program). Inside Solana Playground's **Build & Deploy** sidebar, you can find your @@ -232,7 +232,7 @@ Playground utilities. ### Call the program To execute your on chain program, you must send a -[transaction](https://docs.solana.com/developing/programming-model/transactions) +[transaction](/docs/developing/programming-model/transactions.md) to it. Each transaction submitted to the Solana blockchain contains a listing of instructions (and the program's that instruction will interact with). @@ -314,7 +314,7 @@ re-execute your program. See the links below to learn more about writing Solana programs, and setting up your local development environment: -- [Setup your local development environment](./setup-local-development.md) -- [Overview of writing Solana programs](https://docs.solana.com/developing/on-chain-programs/overview) -- [Learn more about developing Solana programs with Rust](https://docs.solana.com/developing/on-chain-programs/developing-Rust) -- [Debugging on chain programs](https://docs.solana.com/developing/on-chain-programs/debugging) +- [Setup your local development environment](/content/guides/getstarted/setup-local-development.md) +- [Overview of writing Solana programs](/docs/developing/on-chain-programs/overview.md) +- [Learn more about developing Solana programs with Rust](/docs/developing/on-chain-programs/developing-rust.md) +- [Debugging on chain programs](/docs/developing/on-chain-programs/debugging.md) From cdf9f9d10041376a7745abeb3ea661534d4e00a1 Mon Sep 17 00:00:00 2001 From: Chip Thien Date: Sat, 9 Dec 2023 14:38:44 -0600 Subject: [PATCH 2/3] Run prettier:fix --- .../getstarted/hello-world-in-your-browser.md | 25 ++++++++++--------- 1 file changed, 13 insertions(+), 12 deletions(-) diff --git a/content/guides/getstarted/hello-world-in-your-browser.md b/content/guides/getstarted/hello-world-in-your-browser.md index 40bcbe74e..637546024 100644 --- a/content/guides/getstarted/hello-world-in-your-browser.md +++ b/content/guides/getstarted/hello-world-in-your-browser.md @@ -69,10 +69,11 @@ icon and naming your project `hello_world`. ### Create a Playground wallet -Normally with [local development](/content/guides/getstarted/setup-local-development.md), you will need -to create a file system wallet for use with the Solana CLI. But with the Solana -Playground, you only need to click a few buttons to create a browser based -wallet. +Normally with +[local development](/content/guides/getstarted/setup-local-development.md), you +will need to create a file system wallet for use with the Solana CLI. But with +the Solana Playground, you only need to click a few buttons to create a browser +based wallet. > Your _Playground Wallet_ will be saved in your browser's local storage. > Clearing your browser cache will remove your saved wallet. When creating a new @@ -86,7 +87,9 @@ click "**Continue**". After your Playground Wallet is created, you will notice the bottom of the window now states your wallet's address, your SOL balance, and the Solana cluster you are connected to (Devnet is usually the default/recommended, but a -"localhost" [test validator](/content/guides/getstarted/setup-local-development.md) is also acceptable). +"localhost" +[test validator](/content/guides/getstarted/setup-local-development.md) is also +acceptable). ## Create a Solana program @@ -139,9 +142,8 @@ Every on chain program should return the `Ok` tells the Solana runtime that your program executed successfully without errors. Our program above will simply -[log a message](/docs/developing/on-chain-programs/debugging.md#logging) -of "_Hello, world!_" to the blockchain cluster, then gracefully exit with -`Ok(())`. +[log a message](/docs/developing/on-chain-programs/debugging.md#logging) of +"_Hello, world!_" to the blockchain cluster, then gracefully exit with `Ok(())`. ### Build your program @@ -179,8 +181,7 @@ solana airdrop 2 ### Find your program id When executing a program using -[web3.js](/docs/developing/clients/javascript-reference.md) or -from +[web3.js](/docs/developing/clients/javascript-reference.md) or from [another Solana program](/docs/developing/programming-model/calling-between-programs.md), you will need to provide the `program id` (aka public address of your program). @@ -232,8 +233,8 @@ Playground utilities. ### Call the program To execute your on chain program, you must send a -[transaction](/docs/developing/programming-model/transactions.md) -to it. Each transaction submitted to the Solana blockchain contains a listing of +[transaction](/docs/developing/programming-model/transactions.md) to it. Each +transaction submitted to the Solana blockchain contains a listing of instructions (and the program's that instruction will interact with). Here we create a new transaction and add a single `instruction` to it: From 0567122c4c49a612f865fc340370721862d7d11d Mon Sep 17 00:00:00 2001 From: nickfrosty Date: Fri, 15 Dec 2023 14:19:14 -0500 Subject: [PATCH 3/3] refactor: updated links per docs migration --- .../getstarted/hello-world-in-your-browser.md | 31 +++++++++---------- 1 file changed, 15 insertions(+), 16 deletions(-) diff --git a/content/guides/getstarted/hello-world-in-your-browser.md b/content/guides/getstarted/hello-world-in-your-browser.md index 637546024..5e6616783 100644 --- a/content/guides/getstarted/hello-world-in-your-browser.md +++ b/content/guides/getstarted/hello-world-in-your-browser.md @@ -116,8 +116,8 @@ use solana_program::{ Every Solana program must define an `entrypoint` that tells the Solana runtime where to start executing your on chain code. Your program's -[entrypoint](/docs/developing/on-chain-programs/developing-rust.md#program-entrypoint) -should provide a public function named `process_instruction`: +[entrypoint](/docs/programs/lang-rust.md#program-entrypoint) should provide a +public function named `process_instruction`: ```rust // declare and export the program's entrypoint @@ -142,8 +142,8 @@ Every on chain program should return the `Ok` tells the Solana runtime that your program executed successfully without errors. Our program above will simply -[log a message](/docs/developing/on-chain-programs/debugging.md#logging) of -"_Hello, world!_" to the blockchain cluster, then gracefully exit with `Ok(())`. +[log a message](/docs/programs/debugging.md#logging) of "_Hello, world!_" to the +blockchain cluster, then gracefully exit with `Ok(())`. ### Build your program @@ -180,10 +180,9 @@ solana airdrop 2 ### Find your program id -When executing a program using -[web3.js](/docs/developing/clients/javascript-reference.md) or from -[another Solana program](/docs/developing/programming-model/calling-between-programs.md), -you will need to provide the `program id` (aka public address of your program). +When executing a program using [web3.js](/docs/clients/javascript-reference.md) +or from [another Solana program](/docs/core/cpi.md), you will need to provide +the `program id` (aka public address of your program). Inside Solana Playground's **Build & Deploy** sidebar, you can find your `program id` under the **Program Credentials** dropdown. @@ -205,8 +204,8 @@ chain program using JavaScript. Specifically, will use the open source to aid in our client application. > This web3.js package is an abstraction layer on top of the -> [JSON RPC API](/api) that reduced the need for rewriting common boilerplate, -> helping to simplify your client side application code. +> [JSON RPC API](/docs/rpc.md) that reduced the need for rewriting common +> boilerplate, helping to simplify your client side application code. ### Initialize client @@ -233,9 +232,9 @@ Playground utilities. ### Call the program To execute your on chain program, you must send a -[transaction](/docs/developing/programming-model/transactions.md) to it. Each -transaction submitted to the Solana blockchain contains a listing of -instructions (and the program's that instruction will interact with). +[transaction](/docs/core/transactions.md) to it. Each transaction submitted to +the Solana blockchain contains a listing of instructions (and the program's that +instruction will interact with). Here we create a new transaction and add a single `instruction` to it: @@ -316,6 +315,6 @@ See the links below to learn more about writing Solana programs, and setting up your local development environment: - [Setup your local development environment](/content/guides/getstarted/setup-local-development.md) -- [Overview of writing Solana programs](/docs/developing/on-chain-programs/overview.md) -- [Learn more about developing Solana programs with Rust](/docs/developing/on-chain-programs/developing-rust.md) -- [Debugging on chain programs](/docs/developing/on-chain-programs/debugging.md) +- [Overview of writing Solana programs](/docs/programs/index.md) +- [Learn more about developing Solana programs with Rust](/docs/programs/lang-rust.md) +- [Debugging on chain programs](/docs/programs/debugging.md)