| 1 | #pragma once |
|---|---|
| 2 | |
| 3 | #include "units/unit.hpp" |
| 4 | |
| 5 | #include <string> |
| 6 | |
| 7 | struct Symlink : public Unit |
| 8 | { |
| 9 | explicit Symlink(const std::string &id, toml::table &table, std::shared_ptr<const Template> template_ = nullptr, const ArgumentMap &args = {}); |
| 10 | |
| 11 | const std::string linkfile; |
| 12 | const std::string target; |
| 13 | |
| 14 | private: |
| 15 | UnitType GetType() const override |
| 16 | { |
| 17 | return UnitType::Symlink; |
| 18 | } |
| 19 | bool Start() override; |
| 20 | bool Stop() override; |
| 21 | }; |
| 22 |