Add desktop entry; Add readme; Add installation script;

This commit is contained in:
Gabriel Bjørnager Jensen 2025-03-02 13:19:07 +01:00
parent 5567509554
commit 48a8fe94a2
6 changed files with 62 additions and 2 deletions

View file

@ -3,6 +3,12 @@
This is the changelog of Bedrock.
See `README.md` for more information.
## 0.3.1
* Add desktop entry
* Add readme
* Add installation script
## 0.3.0
* Finalise custom level loading

View file

@ -1,6 +1,6 @@
[package]
name = "bedrock"
version = "0.3.0"
version = "0.3.1"
authors = ["Achernar", "Gabriel Bjørnager Jensen"]
edition = "2024"
repository = "ssh://git@ssh.mandelbrot.dk:bedrock"

11
README.md Normal file
View file

@ -0,0 +1,11 @@
# Bedrock
*Bedrock* is an upcomming video game developed at [Achernar](https://achernar.io/).
## Installation
Use the provided `install.sh` script to install Bedrock:
```
install.sh <base_directory>
```

9
bedrock.desktop Normal file
View file

@ -0,0 +1,9 @@
[Desktop Entry]
Type=Application
Version=1.5
Name=Bedroc"
GenericName=Artillery Game
Icon=bedrock
Exec=bedrock
Categories=Game;StrategyGame;X-ArtilleryGame;
SingleMainWindow=true

34
install.sh Executable file
View file

@ -0,0 +1,34 @@
#!/usr/bin/env sh
base_dir="${1}"
if [ -z "${base_dir}" ]
then
echo "missing base directory"
echo "Usage:"
echo " ./install.sh <base_directory>"
exit
fi
if ! [ -e "target/release/bedrock" ]
then
echo "executable has not bee build"
echo "note: build using \`cargo +nightly build --release\`"
exit
fi
notify() {
echo "${@}"
"${@}"
}
notify mkdir -pm755 "${base_dir}/usr/bin"
notify mkdir -pm755 "${base_dir}/usr/share/applications"
notify mkdir -pm755 "${base_dir}/usr/share/pixmaps"
notify install -m755 "target/release/bedrock" "${base_dir}/usr/bin/bedrock"
notify install -m644 "bedrock.svg" "${base_dir}/usr/share/pixmaps/bedrock.svg"
notify desktop-file-install --dir="${base_dir}/usr/share/applications" "bedrock.desktop"

View file

@ -14,7 +14,7 @@ impl Version {
pub const CURRENT: Self = Self {
major: 0x0,
minor: 0x3,
patch: 0x0,
patch: 0x1,
pre: None,
};
}