From: Elan Ruusamäe <nu...@co...> - 2017-11-11 14:27:44
|
Elan Ruusamäe 2017-11-10 06:10:01 +0900 (Fri, 10 Nov 2017) New Revision: fbda9a2ca605f098d42a4d236291418738feb2f6 https://github.com/ruby-gnome2/native-package-installer/commit/fbda9a2ca605f098d42a4d236291418738feb2f6 Merged 5e95ae8: Merge pull request #6 from glensc/pld-support Message: add pld-linux platform Added files: lib/native-package-installer/platform/pld-linux.rb Modified files: lib/native-package-installer/platform.rb Modified: lib/native-package-installer/platform.rb (+1 -0) =================================================================== --- lib/native-package-installer/platform.rb 2017-06-28 00:27:01 +0900 (39e88c3) +++ lib/native-package-installer/platform.rb 2017-11-10 06:10:01 +0900 (510edb7) @@ -43,6 +43,7 @@ require "native-package-installer/platform/redhat" require "native-package-installer/platform/suse" require "native-package-installer/platform/alt-linux" require "native-package-installer/platform/arch-linux" +require "native-package-installer/platform/pld-linux" require "native-package-installer/platform/homebrew" Added: lib/native-package-installer/platform/pld-linux.rb (+40 -0) 100644 =================================================================== --- /dev/null +++ lib/native-package-installer/platform/pld-linux.rb 2017-11-10 06:10:01 +0900 (ec9c7e8) @@ -0,0 +1,40 @@ +# Copyright (C) 2017 Ruby-GNOME2 Project Team +# +# This library is free software: you can redistribute it and/or modify +# it under the terms of the GNU Lesser General Public License as published by +# the Free Software Foundation, either version 3 of the License, or +# (at your option) any later version. +# +# This program is distributed in the hope that it will be useful, +# but WITHOUT ANY WARRANTY; without even the implied warranty of +# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the +# GNU Lesser General Public License for more details. +# +# You should have received a copy of the GNU Lesser General Public License +# along with this program. If not, see <http://www.gnu.org/licenses/>. + +class NativePackageInstaller + module Platform + class PldLinux + Platform.register(self) + + class << self + def current_platform? + ExecutableFinder.exist?("poldek") + end + end + + def package(spec) + spec[:arch_linux] + end + + def install_command + "poldek --up -u" + end + + def need_super_user_priviledge? + true + end + end + end +end |