gsd-cli 0.1.32 → 0.1.33

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (4) hide show
  1. checksums.yaml +4 -4
  2. data/lib/cli.rb +1 -1
  3. data/lib/game_template.rb +5 -5
  4. metadata +1 -1
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA256:
3
- metadata.gz: '0168a95c7438e496dfe910ce5eb9ca30b0592c25d921f1d582e93c4382855e35'
4
- data.tar.gz: 72ef280ffca4de596f7c088bf16525b5fdcd282d225721990bfaa07c2a488e78
3
+ metadata.gz: 88010a2f2d174298334b1ce579b39f537ef186baa01ca6d638228490e52185a4
4
+ data.tar.gz: b0468cf23ad58c3e25ce3f05ca087c125a4a85ea9eeb5038723b9bb3e984db6b
5
5
  SHA512:
6
- metadata.gz: 83df590e3ee81a4f939259bfe711cd1fe19e3dec80b55abfd851aa3bfdde715085d478b0fee2faeb702676816858f0bb5b72bb1451f704267149d1991ce32a81
7
- data.tar.gz: 0fe02c562dd3aaf487b94e0188a47a67f60aaf306f61ac2bdc80c435d3e24d85b0ba486d26a460d8fb702803ffc6f4304a1c724a3052436534afb421403f1501
6
+ metadata.gz: f6ffb2e213e12e76e543643fd0ce0b7a2f9a3919a725e484f6e95e87ef6d72c3788379c2bc5d91cfd342653cef0516e215b27deb71fa29d83212e1204d1fa489
7
+ data.tar.gz: 846065044fb4639d0021b3543aa23eb0360f9be1de61801f231d0c02978166afcfd97afaed71ee64621a922068408da2f952d45014168ae9e25149c845c15418
data/lib/cli.rb CHANGED
@@ -3,7 +3,7 @@
3
3
  require "commander/import"
4
4
 
5
5
  program :name, "gsd-cli"
6
- program :version, "0.1.32"
6
+ program :version, "0.1.33"
7
7
  program :description, "A cli tool to deploy & manage dedicated game servers on Linux"
8
8
 
9
9
  require "cli/install"
data/lib/game_template.rb CHANGED
@@ -52,7 +52,7 @@ class GameTemplate
52
52
  install_steam_server(install_path, steam_login)
53
53
  end
54
54
  @game.post_install(install_path) if defined? @game.post_install
55
- create_unit_file(`which gsd-cli`.strip(), install_path)
55
+ create_unit_file(install_path)
56
56
  end
57
57
 
58
58
  def update(install_path)
@@ -72,21 +72,21 @@ class GameTemplate
72
72
  system("$(which steamcmd) #{steam_login} +force_install_dir #{install_path} +app_update #{@game.app_id} validate +quit")
73
73
  end
74
74
 
75
- def create_unit_file(cli_path, install_path)
75
+ def create_unit_file(install_path)
76
76
  file_path = "/tmp/#{@game.name}.service"
77
77
  `touch #{file_path}`
78
- `echo #{unit_file_contents} >> #{file_path}`
78
+ `echo #{unit_file_contents(install_path)} >> #{file_path}`
79
79
  system("mv -f #{"/tmp/#{@game.name}.service"} /etc/systemd/system/#{@game.name}.service")
80
80
  end
81
81
 
82
82
  def unit_file_contents(cli_path, install_path)
83
83
  "[Unit]
84
84
  After=network.target
85
- Description=#{@desc}
85
+ Description=Daemon for #{@game.name} dedicated server
86
86
  [Install]
87
87
  WantedBy=default.target
88
88
  [Service]
89
89
  Type=simple
90
- ExecStart=#{cli_path} run #{@game.name} --path #{install_path}"
90
+ ExecStart=#{`which gsd-cli`.strip()} run #{@game.name} --path #{install_path}"
91
91
  end
92
92
  end
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: gsd-cli
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.1.32
4
+ version: 0.1.33
5
5
  platform: ruby
6
6
  authors:
7
7
  - Egee