Skip to content

Commit 2d76aee

Browse files
feat(0.3.0): anchor content
2 parents 4f6b1b6 + 203c926 commit 2d76aee

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

42 files changed

+11988
-7058
lines changed

.devcontainer/devcontainer.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -3,7 +3,7 @@
33
"vscode": {
44
"extensions": [
55
"dbaeumer.vscode-eslint",
6-
6+
77
"freeCodeCamp.freecodecamp-dark-vscode-theme"
88
]
99
}

.gitignore

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2,8 +2,9 @@ target
22
node_modules
33
Cargo.lock
44
!.gitkeep
5-
.freeCodeCamp/dist
5+
__test
66

77
# Should be included in repo, but does not get updated
88
.logs
99
test-ledger
10+
.anchor

.gitpod.Dockerfile

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,11 @@
11
FROM gitpod/workspace-full:latest
22

3+
ARG REPO_NAME=solana-curriculum
4+
ARG HOMEDIR=/workspace/$REPO_NAME
5+
6+
WORKDIR ${HOMEDIR}
7+
ENV HOME=${HOMEDIR}
8+
39
RUN bash -c 'VERSION="18" \
410
&& source $HOME/.nvm/nvm.sh && nvm install $VERSION \
511
&& nvm use $VERSION && nvm alias default $VERSION'

.gitpod.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -12,5 +12,5 @@ ports:
1212
# TODO: See about publishing to Open VSX for smoother process
1313
vscode:
1414
extensions:
15-
- https://github.com/freeCodeCamp/courses-vscode-extension/releases/download/v1.7.4/freecodecamp-courses-1.7.4.vsix
15+
- https://github.com/freeCodeCamp/courses-vscode-extension/releases/download/v1.7.5/freecodecamp-courses-1.7.5.vsix
1616
- https://github.com/freeCodeCamp/freecodecamp-dark-vscode-theme/releases/download/v1.0.0/freecodecamp-dark-vscode-theme-1.0.0.vsix

.vscode/settings.json

Lines changed: 5 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,6 @@
22
"files.exclude": {
33
".devcontainer": false,
44
".editorconfig": false,
5-
".freeCodeCamp": false,
65
".git": false,
76
".github": false,
87
".gitignore": false,
@@ -29,9 +28,12 @@
2928
"learn-how-to-set-up-solana-by-building-a-hello-world-smart-contract": false,
3029
"learn-how-to-interact-with-on-chain-programs": false,
3130
"build-a-smart-contract": false,
32-
"build-a-university-certification-nft": false,
3331
"learn-solanas-token-program-by-minting-a-fungible-token": false,
34-
"learn-the-metaplex-sdk-by-minting-an-nft": false
32+
"learn-the-metaplex-sdk-by-minting-an-nft": false,
33+
"build-a-university-certification-nft": false,
34+
"learn-anchor-by-building-tic-tac-toe-part-1": false,
35+
"learn-anchor-by-building-tic-tac-toe-part-2": false,
36+
"build-an-anchor-leaderboard": false
3537
},
3638
"terminal.integrated.profiles.linux": {
3739
"bash": {
@@ -41,9 +43,5 @@
4143
}
4244
},
4345
"terminal.integrated.defaultProfile.linux": "bash",
44-
"rust-analyzer.linkedProjects": [
45-
"learn-how-to-set-up-solana-by-building-a-hello-world-smart-contract/src/program-rust/Cargo.toml",
46-
"learn-how-to-interact-with-on-chain-programs/src/program-rust/Cargo.toml"
47-
],
4846
"workbench.colorTheme": "freeCodeCamp Dark Theme"
4947
}

Dockerfile

Lines changed: 7 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -5,6 +5,7 @@ ARG REPO_NAME=solana-curriculum
55
ARG HOMEDIR=/workspace/$REPO_NAME
66

77
ENV TZ="America/New_York"
8+
ENV HOME=/workspace
89

910
RUN apt-get update && apt-get install -y sudo
1011

@@ -33,17 +34,22 @@ RUN sudo apt-get install -y nodejs
3334
# Rust
3435
RUN sudo apt-get install -y build-essential
3536
RUN curl https://sh.rustup.rs -sSf | sh -s -- -y
36-
ENV PATH="/root/.cargo/bin:${PATH}"
37+
ENV PATH="/workspace/.cargo/bin:${PATH}"
3738

3839
# Solana
3940
RUN sh -c "$(curl -sSfL https://release.solana.com/stable/install)"
41+
# Anchor
42+
RUN cargo install --git https://github.com/coral-xyz/anchor avm --locked --force && avm install 0.28.0 && avm use 0.28.0
4043

4144
# /usr/lib/node_modules is owned by root, so this creates a folder ${USERNAME}
4245
# can use for npm install --global
4346
WORKDIR ${HOMEDIR}
4447
RUN mkdir ~/.npm-global
4548
RUN npm config set prefix '~/.npm-global'
4649

50+
# Yarn
51+
RUN npm install -g yarn
52+
4753
# Configure course-specific environment
4854
COPY . .
4955
WORKDIR ${HOMEDIR}

LICENSE

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
BSD 3-Clause License
22

3-
Copyright (c) 2022, Shaun Hamilton
3+
Copyright (c) 2022-2023, freeCodeCamp
44
All rights reserved.
55

66
Redistribution and use in source and binary forms, with or without

README.md

Lines changed: 17 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1 +1,18 @@
11
# freeCodeCamp: Solana Curriculum
2+
3+
Get started here: https://web3.freecodecamp.org/solana
4+
5+
## Projects
6+
7+
| Project | Description |
8+
| ------------------------------------------------------------------- | --------------------------------------------------------------------------------------------------------------------------------------------------- |
9+
| Learn How to Set Up Solana by Building a Hello World Smart Contract | In this course, you will learn how to set up Solana by building a simple hello world contract. |
10+
| Learn How to Interact with On-Chain Programs | In this course, you will learn how to write the client code to interact with your previously deployed hello world smart contract. |
11+
| Build a Smart Contract | In this integrated project, you will use what you previously learnt to build a smart contract, and interact with it. |
12+
| Learn Solana's Token Program by Minting a Fungible Token | In this course, you will learn how to use Solana's token program by minting a fungible token. |
13+
| Learn the Metaplex SDK by Minting an NFT | In this course, you will learn how to use the Metaplex JS SDK to mint an NFT. |
14+
| Build a University Certification NFT | In this integrated project, you will use what you previously learnt to build out the logic for an NFT-issuing system for university certifications. |
15+
| Learn Anchor by Building Tic-Tac-Toe: Part 1 | In this course, you will learn how to use Anchor, a framework for building smart contracts on Solana, to build an on-chain Tic-Tac-Toe game. |
16+
| Learn Anchor by Building Tic-Tac-Toe: Part 2 | In this course, you will learn how to test the previously built Tic-Tac-Toe game. |
17+
| Build an Anchor Leaderboard | In this integrated project, you will use what you previously learnt to build the program logic for a game leaderboard |
18+
| More Coming Soon... | Keep an eye out for more projects on their way |

bash/.bashrc

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -122,6 +122,8 @@ for i in $(ls -A $HOME/.bashrc.d/); do source $HOME/.bashrc.d/$i; done
122122

123123
. "$HOME/.cargo/env"
124124

125+
export PATH="$HOME/.npm-global/bin:$PATH"
126+
125127
# freeCodeCamp - Needed for most tests to work
126128

127129
WD=/workspace/solana-curriculum
Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,7 @@
1+
2+
.anchor
3+
.DS_Store
4+
target
5+
**/*.rs.bk
6+
node_modules
7+
test-ledger

0 commit comments

Comments
 (0)