Update README.md

This commit is contained in:
Kevin Veen-Birkenbach 2025-03-04 20:56:32 +01:00 committed by GitHub
parent 0a363d227d
commit 181bed3df7
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194

View File

@ -1,2 +1,58 @@
# create-linux-swapfile
Creates a linux swapfile
# SwapForge (swafo) 🔄
[![License: MIT](https://img.shields.io/badge/License-MIT-yellow.svg)](LICENSE) [![GitHub stars](https://img.shields.io/github/stars/kevinveenbirkenbach/swapforge.svg?style=social)](https://github.com/kevinveenbirkenbach/swapforge/stargazers)
SwapForge is a simple yet powerful bash script for creating and managing Linux swapfiles. Whether you need to boost system performance or add swap space to your setup, SwapForge automates the process quickly and reliably.
---
## 🛠 Features
- **Automated Swapfile Creation:** Easily create a swapfile with a specified size.
- **FSTAB Integration:** Automatically updates `/etc/fstab` to ensure the swapfile is mounted at boot.
- **Safety Checks:** Skips swapfile creation if an entry already exists.
- **Simple CLI Interface:** Run the script with a single command.
---
## 📥 Installation
Install SwapForge using [Kevin's Package Manager](https://github.com/kevinveenbirkenbach/package-manager) under the alias `swafo`:
```bash
package-manager install swafo
```
This command installs SwapForge globally, making it available as `swafo` in your terminal. 🚀
---
## 🚀 Usage
Run SwapForge from the command line by specifying the desired swapfile size. For example, to create a 2G swapfile:
```bash
swafo 2G
```
The script will check if a swapfile entry already exists in `/etc/fstab`. If not, it will create the swapfile, set the correct permissions, format it as swap, activate it, and append the necessary entry to `/etc/fstab`.
---
## 🧑‍💻 Author
Developed by **Kevin Veen-Birkenbach**
- 📧 [kevin@veen.world](mailto:kevin@veen.world)
- 🌐 [https://www.veen.world](https://www.veen.world)
---
## 📜 License
This project is licensed under the **MIT License**. See the [LICENSE](LICENSE) file for details.
---
## 🤝 Contributions
Contributions are welcome! Feel free to fork the repository, submit pull requests, or open issues if you have suggestions or encounter any problems. Let's make Linux swap management easier together! 😊