Ecosyste.ms: Awesome
An open API service indexing awesome lists of open source software.
https://github.com/slytomcat/yandex-disk-simulator
yandex-disk utility simulator for integration tests (Linux)
https://github.com/slytomcat/yandex-disk-simulator
go golang linux simulator yandex-disk
Last synced: about 1 month ago
JSON representation
yandex-disk utility simulator for integration tests (Linux)
- Host: GitHub
- URL: https://github.com/slytomcat/yandex-disk-simulator
- Owner: slytomcat
- License: gpl-3.0
- Created: 2018-12-22T11:58:25.000Z (about 6 years ago)
- Default Branch: master
- Last Pushed: 2024-09-04T20:47:49.000Z (4 months ago)
- Last Synced: 2024-09-06T05:42:23.372Z (4 months ago)
- Topics: go, golang, linux, simulator, yandex-disk
- Language: Go
- Size: 154 KB
- Stars: 4
- Watchers: 2
- Forks: 3
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
- License: LICENSE
Awesome Lists containing this project
README
# yandex-disk-simulator
[![Go](https://github.com/slytomcat/yandex-disk-simulator/actions/workflows/go.yml/badge.svg)](https://github.com/slytomcat/yandex-disk-simulator/actions/workflows/go.yml)**yandex-disk-simulator** is a *yandex-disk* utility simulator for integration tests (Linux).
You can get compiled binaries (ELF) for linux/amd64 and linux/386 platforms from [last release](https://github.com/slytomcat/yandex-disk-simulator/releases/latest) or bild it yourself.
There is no additional libraries requirements to run the simulator.
**Building requirements:**
- go v.1.16 and higher**Buiding:**
go get -d github.com/slytomcat/yandex-disk-simulator
go build yandex-disk-simulator**Usage**
Help message:
Usage:
yandex-disk-simulator
Commands:
start starts the daemon and begin starting events simulation
stop stops the daemon
status get the daemon status
sync begin the synchronization events simulation
error begin short time error simulation
help output this help message and exit
version output version information and exit
setup prepares the simulation environment. It creates the configuration and
token files in Sim_ConfDir and the synchronization directory in Sim_SyncDir.
Environment variables Sim_ConfDir and Sim_SyncDir should be set in advance,
other ways the default paths will be used.
Setup process doesn't require any input in the terminal.
Simulator commands:
daemon start as a daemon (Don't use it !!!)
Environment variables (used in setup):
Sim_SyncDir can be used to set synchronized directory path (default: ~/Yandex.Disk)
Sim_ConfDir can be used to set configuration directory path (default: ~/.config/yandex-disk)**NOTE**
This simulator doesn't handle any additional command or option of original yandex-disk utility except the commands listed above.
In order to setup simulator and it's environment do the folloving steps:
1. set *Sim_SyncDir* (synchronized directory path) and *Sim_ConfDir* (configuration directory path) environment variables.
2. runyandex-disk-similator setup
**IMPORTANT**
If *Sim_SyncDir* and *Sim_ConfDir* are not set then *"$HOME/Yandex.Disk"* is used as syncronizition folder and *"$HOME/.config/yandex-disk"* is used as configuration folder. Those are same paths as original *yandex-disk* uses. And this can broke the original *yandex-disk* configuration.
**GOOD IDEA**
To use it as yandex-disk simulator consider renaming the *yandex-disk-similator* to *yandex-disk* and put it in the PATH before the original yandex-disk (if it is installed).