Review README files and comment style
This commit is contained in:
parent
8c22e68c2a
commit
5e2b5aef34
5 changed files with 35 additions and 35 deletions
62
README.md
62
README.md
|
|
@ -14,6 +14,7 @@ Raylib-cs targets net8.0, net10.0 and uses the [official 6.0 release](https://gi
|
|||
to build the native libraries.
|
||||
|
||||
### Version 8.1.0 of Raylib-cs supports the following runtimes:
|
||||
|
||||
- **browser-wasm** *(raylib-6.0_webassembly)* 🆕
|
||||
- **linux-x64** *(raylib-6.0_linux_amd64)*
|
||||
- **osx-arm64** *(raylib-6.0_macos)*
|
||||
|
|
@ -24,7 +25,6 @@ to build the native libraries.
|
|||
The following frameworks are deprecated (fall back to Version 7.x if required):
|
||||
- net6.0 (end of life)
|
||||
|
||||
|
||||
## Status
|
||||
|
||||
Raylib-cs is passively maintained. Occasional updates may be released from time to time. Pull requests may be
|
||||
|
|
@ -34,14 +34,14 @@ accepted if they don't have a large maintenance burden.
|
|||
|
||||
This is the preferred method to get started.
|
||||
|
||||
1) Pick a folder in which you would like to start a raylib project. For example, "MyRaylibCSProj."
|
||||
1) Pick a folder in which you would like to start a raylib project. For example, "HelloRaylibCS."
|
||||
2) Then from a terminal (for example, a VSCode terminal), whilst in the directory you just created
|
||||
run the following commands. (Please keep in mind .NET should already be installed on your system)
|
||||
|
||||
```
|
||||
```sh
|
||||
dotnet new console
|
||||
```
|
||||
```
|
||||
```sh
|
||||
dotnet add package Raylib-cs
|
||||
```
|
||||
|
||||
|
|
@ -65,25 +65,6 @@ otherwise the command won't work.
|
|||
|
||||
5. Start coding!
|
||||
|
||||
## Building from source
|
||||
|
||||
The `Examples` and `Raylib-cs.Tests` projects consume the binding as a NuGet package, and the in-repo
|
||||
version may not be published on nuget.org yet. Pack it once into the local feed before the first build:
|
||||
|
||||
```
|
||||
dotnet pack Raylib-cs -c Release -o nuget
|
||||
dotnet build
|
||||
```
|
||||
|
||||
`NuGet.config` points restore at the local `./nuget` feed, so both projects pick up the freshly packed
|
||||
package. If you skip the pack step on a fresh clone, restore fails with NU1301 (the `./nuget` source
|
||||
doesn't exist) or NU1102 (Raylib-cs not found) — running the pack command fixes both.
|
||||
|
||||
When iterating on the binding itself, note that NuGet caches the extracted package by version and
|
||||
ignores repacks of the same version. After repacking, delete the old package from `./nuget` and clear
|
||||
the cached copy (`dotnet nuget locals global-packages --clear`, or delete
|
||||
`~/.nuget/packages/raylib-cs/<version>`) before restoring again.
|
||||
|
||||
## Hello, World!
|
||||
|
||||
```csharp
|
||||
|
|
@ -115,21 +96,40 @@ internal static class Program
|
|||
}
|
||||
```
|
||||
|
||||
## Building the examples locally
|
||||
## Building from source
|
||||
|
||||
The `Examples` project references the sibling `Raylib-cs` project by default, so local changes to the
|
||||
bindings are picked up directly:
|
||||
The `Examples` and `Raylib-cs.Tests` projects reference the sibling `Raylib-cs` project by default, so local changes to the the bindings are picked up directly:
|
||||
|
||||
```
|
||||
```sh
|
||||
dotnet run --project Examples
|
||||
```
|
||||
|
||||
To build the examples against the Raylib-cs NuGet package instead (the version set by
|
||||
`RaylibCsVersion` in [Directory.Build.props](Directory.Build.props)), set `UseRaylibCsPackage`:
|
||||
|
||||
```sh
|
||||
dotnet test
|
||||
```
|
||||
|
||||
Both projects can also consume the binding as a NuGet package but the in-repo version may not be published on nuget.org
|
||||
yet. Pack it once into the local feed before the first build. Then to run against the Raylib-cs NuGet package (the
|
||||
version set by `RaylibCsVersion` in [Directory.Build.props](Directory.Build.props)), set `UseRaylibCsPackage`:
|
||||
|
||||
```sh
|
||||
dotnet pack Raylib-cs -c Release -o nuget
|
||||
dotnet build
|
||||
```
|
||||
```sh
|
||||
dotnet run --project Examples -p:UseRaylibCsPackage=true
|
||||
```
|
||||
```sh
|
||||
dotnet test -p:UseRaylibCsPackage=true
|
||||
```
|
||||
|
||||
Note that `NuGet.config` points restore at the local `./nuget` feed, so both projects pick up the freshly packed
|
||||
package. If you skip the pack step on a fresh clone, restore fails with NU1301 (the `./nuget` source
|
||||
doesn't exist) or NU1102 (Raylib-cs not found) - running the pack command fixes both.
|
||||
|
||||
When iterating on the binding itself, note that NuGet caches the extracted package by version and
|
||||
ignores repacks of the same version. After repacking, delete the old package from `./nuget` and clear
|
||||
the cached copy (`dotnet nuget locals global-packages --clear`, or delete
|
||||
`~/.nuget/packages/raylib-cs/<version>`) before restoring again.
|
||||
|
||||
## Contributing
|
||||
|
||||
|
|
|
|||
Loading…
Reference in a new issue