0.1.0-dev.10 • Published 10 months ago

@timo972/altv-cli v0.1.0-dev.10

Weekly downloads
-
License
MIT
Repository
github
Last release
10 months ago

altv cli

Incredibly flexible and easy to use altv server manager. Install or update only necessary files, reducing the bandwidth usage and time spent to a minimum. Supports every official module and continues working even on module file renamings by respecting their manifest.json. Extendable to support custom modules, feel free to open a pull request to add compatibility.

Table of Contents

Motivation

There are several altv server updater libraries and scripts out there, but none of them is as flexible and resilient as this one. I was annoyed by the fact that I always had to download the whole server files every time an update released. This is especially annoying if your internet connection poor. Additionally I wanted to have a tool that is able to update the server files even if the module files are renamed. See for example the js-module node library name.

Features

  • Fast
  • Flexible
  • Resilient
  • Supports every official module
  • Supports custom modules
  • Reduces bandwidth usage to a minimum

Planned Features

  • Workspace configs for use of cli without having to set flags every time: altv init -p ./server -b dev -t 30
  • JSON configuration for cdn's
  • CI integrations

Installation

If you have Go installed, you can install the cli with the following command:

go install github.com/timo972/altv-cli/cmd/altv@latest

Otherwise you can use the prebuilt binaries from github releases or npm in the future.

Usage

Type altv --help to get a list of all available commands and flags. Consider using Makefile or a package.json script to simplify the usage.

Example Makefile:

.PHONY: install update verify

dir = ./server
branch = dev
timeout = 30

install:
    altv install -p $dir -b $branch -m server -m data-files -m csharp-module -m js-module -t $timeout
update:
    altv update -p $dir -b $branch -m server -m data-files -m csharp-module -m js-module -t $timeout
verify:
    altv verify -p $dir -b $branch -m server -m data-files -m csharp-module -m js-module -t $timeout

Example package.json:

{
  "scripts": {
    "altv-install": "altv install -p ./server -b dev -m server -m data-files -m csharp-module -m js-module -t 30",
    "altv-update": "altv update -p ./server -b dev -m server -m data-files -m csharp-module -m js-module -t 30",
    "altv-verify": "altv verify -p ./server -b dev -m server -m data-files -m csharp-module -m js-module -t 30"
  }
}

This way you can use make install, make update or make verify to install, update or verify your server files. If you prefer using npm, you can use npm run altv-install, npm run altv-update or npm run altv-verify instead.

0.1.0-dev.15

10 months ago

0.1.0-dev.10

10 months ago