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
The table of contents is too big for display.
Diff view
Diff view
  •  
  •  
  •  
16 changes: 16 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,22 @@ All notable changes to this repository are documented here.

The format is based on [Keep a Changelog](https://keepachangelog.com/en/1.1.0/).

## [2026-11-06] - NFT examples get their own folder; realloc becomes resizing-accounts

### Changed

- The NFT examples move out of `tokens/` into a top-level `nft/` folder, matching the
README's new NFTs section: `tokens/nft-minter` is now `nft/minter`,
`tokens/nft-operations` is now `nft/operations`, and
`tokens/token-extensions/nft-meta-data-pointer/anchor-example` is now
`nft/metadata-pointer`. The two Quasar NFT examples point their `quasar-metadata`
path dependency at `../../../tokens/quasar-metadata`, which stays where it is.
- `basics/realloc` is now `basics/resizing-accounts`, under the README title
"Resizing Accounts". The crate names keep `realloc`, the operation the code performs.
- Each old folder keeps only a `README.md` pointing to the new location.
- The Anchor v1 READMEs of the moved examples name their own `anchor-v1/` directory
rather than the `anchor/` one they were copied from.

## [2026-10-28] - Anchor v2 examples on Anchor 2.0.0-rc.2, sending v1 transactions

Anchor 2.0.0-rc.2's test harness, `anchor-v2-testing`, runs on LiteSVM 0.18, which
Expand Down
14 changes: 7 additions & 7 deletions Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -47,9 +47,9 @@ members = [
"basics/program-derived-addresses/native/program",
"basics/program-derived-addresses/pinocchio/program",
"basics/program-derived-addresses/anchor/programs/*",
"basics/realloc/native/program",
"basics/realloc/pinocchio/program",
"basics/realloc/anchor/programs/*",
"basics/resizing-accounts/native/program",
"basics/resizing-accounts/pinocchio/program",
"basics/resizing-accounts/anchor/programs/*",
"basics/rent/native/program",
"basics/rent/pinocchio/program",
"basics/rent/anchor/programs/*",
Expand Down Expand Up @@ -94,12 +94,12 @@ members = [
"tokens/create-token/native/program",
"tokens/token-minter/native/program",
"tokens/transfer-tokens/native/program",
"tokens/nft-minter/native/program",
"nft/minter/native/program",
"tokens/pda-mint-authority/native/program",
"tokens/create-token/anchor/programs/create-token",
"tokens/external-delegate-token-master/anchor/programs/external-delegate-token-master",
"tokens/nft-minter/anchor/programs/nft-minter",
"tokens/nft-operations/anchor/programs/mint-nft",
"nft/minter/anchor/programs/nft-minter",
"nft/operations/anchor/programs/mint-nft",
"tokens/pda-mint-authority/anchor/programs/token-minter",
"tokens/token-minter/anchor/programs/token-minter",
"tokens/transfer-tokens/anchor/programs/transfer-tokens",
Expand All @@ -112,7 +112,7 @@ members = [
"tokens/token-extensions/memo-transfer/anchor/programs/memo-transfer",
"tokens/token-extensions/metadata/anchor/programs/metadata",
"tokens/token-extensions/mint-close-authority/anchor/programs/mint-close-authority",
"tokens/token-extensions/nft-meta-data-pointer/anchor-example/anchor/programs/extension_nft",
"nft/metadata-pointer/anchor/programs/extension_nft",
"tokens/token-extensions/non-transferable/anchor/programs/non-transferable",
"tokens/token-extensions/permanent-delegate/anchor/programs/permanent-delegate",
"tokens/token-extensions/transfer-fee/anchor/programs/transfer-fee",
Expand Down
91 changes: 61 additions & 30 deletions README.md

Large diffs are not rendered by default.

Binary file added assets/book-cover.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
10 changes: 2 additions & 8 deletions basics/realloc/README.md
Original file line number Diff line number Diff line change
@@ -1,9 +1,3 @@
# Realloc
# Moved

Resize a Solana [account](https://solana.com/docs/terminology#account) after it has been created - grow or shrink the data it can hold.

## A note on `realloc` vs `resize`

The runtime method `AccountInfo::realloc` has been deprecated in favor of `AccountInfo::resize` ([anchor#4526](https://github.com/solana-foundation/anchor/issues/4526)). New code should call `AccountInfo::resize`.

The [Anchor](https://solana.com/docs/terminology#anchor) account-constraint macros (`#[account(realloc = ..., realloc::payer = ..., realloc::zero = ...)]`) are **not yet renamed** and still use the `realloc` spelling. That is the correct form to use today; track the issue above for any future change.
This example has moved to [`basics/resizing-accounts`](../resizing-accounts).
9 changes: 9 additions & 0 deletions basics/resizing-accounts/README.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,9 @@
# Realloc

Resize a Solana [account](https://solana.com/docs/terminology#account) after it has been created - grow or shrink the data it can hold.

## A note on `realloc` vs `resize`

The runtime method `AccountInfo::realloc` has been deprecated in favor of `AccountInfo::resize` ([anchor#4526](https://github.com/solana-foundation/anchor/issues/4526)). New code should call `AccountInfo::resize`.

The [Anchor](https://solana.com/docs/terminology#anchor) account-constraint macros (`#[account(realloc = ..., realloc::payer = ..., realloc::zero = ...)]`) are **not yet renamed** and still use the `realloc` spelling. That is the correct form to use today; track the issue above for any future change.
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,7 @@ See also: [Realloc overview](../README.md) and the [repository catalog](../../..

## Setup

From this directory (`basics/realloc/anchor/`):
From this directory (`basics/resizing-accounts/anchor-v1/`):

```bash
anchor build
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,7 @@ See also: [Realloc overview](../README.md) and the [repository catalog](../../..

## Setup

From this directory (`basics/realloc/anchor/`):
From this directory (`basics/resizing-accounts/anchor/`):

```bash
anchor build
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@ See also: [Realloc overview](../README.md) and the [repository catalog](../../..

## Setup

From `basics/realloc/quasar/`:
From `basics/resizing-accounts/quasar/`:

```bash
quasar build
Expand Down
Loading
Loading