From 25c78bf38296995afacc5570c43f73e9924f9ecb Mon Sep 17 00:00:00 2001 From: "S. Hessam M. Mehr" Date: Tue, 21 Aug 2018 17:40:29 +0100 Subject: [PATCH] Update `replace` to Julia 1.0 convention. More `replace` revisions. --- src/WinRPM.jl | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/src/WinRPM.jl b/src/WinRPM.jl index 5ad8bae..f8e98f6 100644 --- a/src/WinRPM.jl +++ b/src/WinRPM.jl @@ -231,7 +231,7 @@ function show(io::IO, pkg::Package) println(io," Arch: ", LibExpat.string_value(pkg["arch"][1])) println(io," URL: ", LibExpat.string_value(pkg["url"][1])) println(io," License: ", LibExpat.string_value(pkg["format/rpm:license"][1])) - print(io," Description: ", replace(LibExpat.string_value(pkg["description"][1]), r"\r\n|\r|\n", "\n ")) + print(io," Description: ", replace(LibExpat.string_value(pkg["description"][1]), r"\r\n|\r|\n" => "\n ")) end function show(io::IO, pkgs::Packages) @@ -417,7 +417,7 @@ function prepare_install(pkg::Union{Package,Packages}) end toupdate = ETree[] filter!(packages) do p - ver = replace(join(rpm_ver(p), ','), r"\s", "") + ver = replace(join(rpm_ver(p), ','), r"\s" => "") oldver = false for entry in p[xpath"format/rpm:provides/rpm:entry[@name]"] provides = entry.attr["name"] @@ -496,7 +496,7 @@ function do_install(package::Package) end end isfile(cpio) && rm(cpio) - ver = replace(join(rpm_ver(package), ','), r"\s", "") + ver = replace(join(rpm_ver(package), ','), r"\s" => "") open(installedlist, isfile(installedlist) ? "r+" : "w+") do installed for entry in package[xpath"format/rpm:provides/rpm:entry[@name]"] provides = entry.attr["name"]