Skip to content

Commit

Permalink
fix leading space in comments
Browse files Browse the repository at this point in the history
  • Loading branch information
jreidinger committed Jan 14, 2015
1 parent 536c243 commit 4a9a454
Show file tree
Hide file tree
Showing 30 changed files with 68 additions and 78 deletions.
10 changes: 0 additions & 10 deletions .rubocop.yml
Expand Up @@ -77,16 +77,6 @@ Style/DoubleNegation:
Style/FileName:
Enabled: false

# Offense count: 12
# Cop supports --auto-correct.
Style/InfiniteLoop:
Enabled: false

# Offense count: 68
# Cop supports --auto-correct.
Style/LeadingCommentSpace:
Enabled: false

# Offense count: 10
# Cop supports --auto-correct.
Style/MethodCallParentheses:
Expand Down
2 changes: 1 addition & 1 deletion Rakefile
Expand Up @@ -5,6 +5,6 @@ Yast::Tasks.configuration do |conf|
conf.obs_target = "SLE_12"
conf.obs_sr_project = "SUSE:SLE-12:Update"
conf.obs_project = "Devel:YaST:SLE-12"
#lets ignore license check for now
# lets ignore license check for now
conf.skip_license_check << /.*/
end
2 changes: 1 addition & 1 deletion library/commandline/src/clients/other_tools_warning.rb
Expand Up @@ -22,7 +22,7 @@
#
# ***************************************************************************

#*
# *
# There may be different ways to configure the system than YaST, e.g. Chef.
# It will periodically overwrite files under its control.
# If it is running, now is a good time to tell the user
Expand Down
6 changes: 3 additions & 3 deletions library/control/src/modules/AutoinstData.rb
Expand Up @@ -39,12 +39,12 @@ def main
#
# Keyboard
#
#global map keyboard = $[];
# global map keyboard = $[];

#
# Language
#
#global string language = "";
# global string language = "";

#
# Mouse, if not autoprobed
Expand All @@ -54,7 +54,7 @@ def main
#
# Clock Settings
#
#global map Clock = $[];
# global map Clock = $[];

# Moved here from AutoinstSoftware.ycp

Expand Down
4 changes: 2 additions & 2 deletions library/control/src/modules/InstError.rb
Expand Up @@ -129,7 +129,7 @@ def ShowErrorPopUp(heading, error_text, details)
0.5,
VBox(
Left(Label(error_text)),
#`VSpacing (1),
# `VSpacing (1),
Left(
details == nil ?
Label(
Expand All @@ -144,7 +144,7 @@ def ShowErrorPopUp(heading, error_text, details)
) :
MinSize(80, 10, RichText(Opt(:plainText, :hstretch), details))
),
#`VSpacing (1),
# `VSpacing (1),
Left(
Label(
Builtins.sformat(
Expand Down
2 changes: 1 addition & 1 deletion library/control/src/modules/InstExtensionImage.rb
Expand Up @@ -48,7 +48,7 @@ def main
Yast.import "Popup"
Yast.import "Stage"

#**
# **
#
# Paths where to download inst-sys extension images are taken
# from '/etc/install.inf'. An extension image contains the
Expand Down
12 changes: 6 additions & 6 deletions library/desktop/src/clients/menu.rb
Expand Up @@ -72,7 +72,7 @@ def main

@non_root_modules = []

#create the list of modules available to non-root users
# create the list of modules available to non-root users
Builtins.foreach(
Convert.convert(@Modules, from: "map", to: "map <string, map>")
) do |name, params|
Expand All @@ -98,7 +98,7 @@ def main

@modules = Builtins.listmap(@groups) do |gr|
all_modules = Desktop.ModuleList(gr)
#filter out root-only stuff if the user is not root (#246015)
# filter out root-only stuff if the user is not root (#246015)
all_modules = Builtins.filter(all_modules) do |t|
Builtins.contains(@non_root_modules, Ops.get_string(t, [0, 0], ""))
end if !@root
Expand All @@ -109,7 +109,7 @@ def main
@first = Ops.get(@groups, 0)
Builtins.y2debug("first=%1", @first)

#do not show groups containing no modules to the user (#309452)
# do not show groups containing no modules to the user (#309452)
@GroupList = Builtins.filter(@GroupList) do |t|
group = Ops.get_string(t, [0, 0], "")
Ops.get(@modules, group) != []
Expand Down Expand Up @@ -203,7 +203,7 @@ def DisplaySplash
end

def OpenMenu
#check if user is root (#246015)
# check if user is root (#246015)
output = Convert.to_map(
SCR.Execute(path(".target.bash_output"), "/usr/bin/id --user")
)
Expand Down Expand Up @@ -267,7 +267,7 @@ def OpenMenu
)
)

#show popup when running as non-root
# show popup when running as non-root
if !@root
Popup.Notify(
_(
Expand All @@ -292,7 +292,7 @@ def Launch(modul)
cmd = ""
ret = nil

#Use UI::RunInTerminal in text-mode only (#237332)
# Use UI::RunInTerminal in text-mode only (#237332)
if textmode
cmd = Builtins.sformat("/sbin/yast %1 %2 >&2", function, argument)
ret = UI.RunInTerminal(cmd)
Expand Down
10 changes: 5 additions & 5 deletions library/desktop/src/modules/Desktop.rb
Expand Up @@ -72,8 +72,8 @@ def ReadLocalizedKey(fname, keypath, key)
ret = ""
fallback = Convert.to_string(SCR.Read(Builtins.add(keypath, key)))

#check if there are any translation in .desktop file
#that is - Name[$lang_code]
# check if there are any translation in .desktop file
# that is - Name[$lang_code]
if @LanguageFull != nil || @LanguageFull != ""
newkey = Builtins.sformat("%1[%2]", key, @LanguageFull)
ret = Convert.to_string(SCR.Read(Builtins.add(keypath, newkey)))
Expand All @@ -86,7 +86,7 @@ def ReadLocalizedKey(fname, keypath, key)
return ret if ret != nil && ret != ""
end

#no translations in .desktop, check desktop_translations.mo then
# no translations in .desktop, check desktop_translations.mo then
msgid = Builtins.sformat("%1(%2): %3", key, fname, fallback)
Builtins.y2debug("Looking for key: %1", msgid)
ret = Builtins.dpgettext(
Expand All @@ -95,7 +95,7 @@ def ReadLocalizedKey(fname, keypath, key)
msgid
)

#probably untranslated - return english name
# probably untranslated - return english name
return fallback if ret == msgid

ret
Expand Down Expand Up @@ -364,7 +364,7 @@ def ParseSingleDesktopFile(file)
)
)

#non-existent file requested
# non-existent file requested
if SCR.Dir(path(".yast2.desktop1.v.\"Desktop Entry\"")) == nil
Builtins.y2error("Unknown desktop file: %1", file)
SCR.UnregisterAgent(path(".yast2.desktop1"))
Expand Down
2 changes: 1 addition & 1 deletion library/general/src/modules/ConfigHistory.rb
Expand Up @@ -467,7 +467,7 @@ def Init
)
return true
end
#ensure the repo exists
# ensure the repo exists
return false if !InitSvnRepository() if !CheckSvnRepository()
return false if !InitDirectories(Recursive()) if !CheckRepoLinked()
CheckAllFilesOutOfVersionControl() if Recursive()
Expand Down
10 changes: 5 additions & 5 deletions library/network/src/modules/NetworkInterfaces.rb
Expand Up @@ -526,7 +526,7 @@ def IsConnected(dev)

return Builtins.deletechars(Ops.get_string(ret, "stdout", ""), "\n") == "1" ? true : false
else
#Assume all devices are connected in testsuite mode
# Assume all devices are connected in testsuite mode
return true
end
end
Expand Down Expand Up @@ -870,7 +870,7 @@ def Write(devregex)
)
)
devmap = Builtins.remove(devmap, "NETMASK")
#TODO : delete NETMASK from config file
# TODO : delete NETMASK from config file
else
if Ops.greater_than(
Builtins.size(Ops.get_string(devmap, "IPADDR", "")),
Expand All @@ -890,7 +890,7 @@ def Write(devregex)
)
)
devmap = Builtins.remove(devmap, "PREFIXLEN")
#TODO : delete PREFIXLEN from config file
# TODO : delete PREFIXLEN from config file
end
end
end
Expand Down Expand Up @@ -925,7 +925,7 @@ def Write(devregex)
)
)
amap = Builtins.remove(amap, "NETMASK")
#TODO : delete NETMASK from config file
# TODO : delete NETMASK from config file
else
if Ops.greater_than(
Builtins.size(Ops.get(amap, "IPADDR", "")),
Expand All @@ -945,7 +945,7 @@ def Write(devregex)
)
)
amap = Builtins.remove(amap, "PREFIXLEN")
#TODO : delete PREFIXLEN from config file
# TODO : delete PREFIXLEN from config file
end
end
Builtins.maplist(amap) do |ak, av|
Expand Down
2 changes: 1 addition & 1 deletion library/network/src/modules/NetworkPopup.rb
Expand Up @@ -66,7 +66,7 @@ def ChooseItem(_title, items, selected)
items = Builtins.maplist(items) do |i|
device_name = NetworkInterfaces.GetValue(i, "NAME")
if device_name == nil || device_name == ""
#TRANSLATORS: Informs that device name is not known
# TRANSLATORS: Informs that device name is not known
device_name = _("Unknown device")
end
if Ops.greater_than(Builtins.size(device_name), 30)
Expand Down
2 changes: 1 addition & 1 deletion library/network/src/modules/SuSEFirewallExpertRules.rb
Expand Up @@ -42,7 +42,7 @@ def main
Yast.import "Netmask"
Yast.import "IP"

#**
# **
# Firewall Expert Rulezz
#
# ATTENTION: You have to call SuSEFirewall::Read() to read the configuration
Expand Down
2 changes: 1 addition & 1 deletion library/network/testsuite/tests/NetworkInterfaces2.rb
Expand Up @@ -22,7 +22,7 @@
#
# ***************************************************************************
module Yast
#inject NetworkInterfaces accessor so we can modify Devices
# inject NetworkInterfaces accessor so we can modify Devices
class NetworkInterfacesClass < Module
attr_accessor :Devices
attr_accessor :OriginalDevices
Expand Down
2 changes: 1 addition & 1 deletion library/network/testsuite/tests/NetworkInterfaces4.rb
Expand Up @@ -22,7 +22,7 @@
#
# ***************************************************************************
module Yast
#inject NetworkInterfaces accessor so we can modify Devices
# inject NetworkInterfaces accessor so we can modify Devices
class NetworkInterfacesClass < Module
attr_accessor :OriginalDevices
end
Expand Down
2 changes: 1 addition & 1 deletion library/network/testsuite/tests/NetworkInterfaces5-Type.rb
Expand Up @@ -55,7 +55,7 @@ def main
Assert.Equal("tap", NetworkInterfaces.GetTypeFromIfcfg(@myvirt))
end, [], nil)

#EOF
# EOF

nil
end
Expand Down
2 changes: 1 addition & 1 deletion library/packages/src/modules/Package.rb
Expand Up @@ -43,7 +43,7 @@ def main
Yast.import "PackageAI"
Yast.import "PackageSystem"

#**
# **
# Packages Manipulation

@FunctionsSystem = {
Expand Down
6 changes: 3 additions & 3 deletions library/packages/src/modules/PackageCallbacks.rb
Expand Up @@ -1862,11 +1862,11 @@ def ScriptProblem(description)
Builtins.y2warning("ScriptProblem: %1", description)

ui = Popup.AnyQuestion3(
"", #symbol focus
"", # symbol focus
description,
Label.RetryButton, #yes_button_message
Label.RetryButton, # yes_button_message
Label.AbortButton, # no_button_message
Label.IgnoreButton, #retry_button_message
Label.IgnoreButton, # retry_button_message
:retry
)

Expand Down
2 changes: 1 addition & 1 deletion library/packages/src/modules/PackageSystem.rb
Expand Up @@ -241,7 +241,7 @@ def DoInstallAndRemoveInt(toinstall, toremove)
any_to_install = Pkg.IsAnyResolvable(:package, :to_install) ||
Pkg.IsAnyResolvable(:patch, :to_install)

#[int successful, list failed, list remaining, list srcremaining]
# [int successful, list failed, list remaining, list srcremaining]
result = Pkg.PkgCommit(0)
Builtins.y2debug("PkgCommit: %1", result)
if result == nil || Ops.get_list(result, 1, []) != []
Expand Down
10 changes: 5 additions & 5 deletions library/packages/src/modules/SlideShow.rb
Expand Up @@ -165,9 +165,9 @@ def main
@_stages = {} # list of the configured stages
@_current_stage = nil # current stage

@_rn_tabs = {} #tabs with release notes
@_relnotes = {} #texts with release notes, product -> text
@_base_product = "" #base product for release notes ordering
@_rn_tabs = {} # tabs with release notes
@_relnotes = {} # texts with release notes, product -> text
@_base_product = "" # base product for release notes ordering
end

# Set the flag that user requested abort of the installation
Expand Down Expand Up @@ -638,7 +638,7 @@ def HelpText
help_text
end

#set the release notes for slide show
# set the release notes for slide show
# @param [map<string,string>] map product name -> release notes text
# @param [string] base product name
def SetReleaseNotes(relnotes, base_product)
Expand All @@ -648,7 +648,7 @@ def SetReleaseNotes(relnotes, base_product)

def add_relnotes_for_product product, relnotes, tabs
id = ProductRelNotesID product
#Translators: Tab name, keep short, %s is product name, e.g. SLES
# Translators: Tab name, keep short, %s is product name, e.g. SLES
tabs << Item(Id(id), _("%s Release Notes") % product)
@_rn_tabs[id] = relnotes
end
Expand Down
2 changes: 1 addition & 1 deletion library/sequencer/testsuite/tests/WS_next.rb
Expand Up @@ -44,7 +44,7 @@ def main
TEST(->() { Sequencer.WS_next(@sequence, "begin", :id3) }, [], nil)
TEST(->() { Sequencer.WS_next(@sequence, "begin", :id3) }, [], nil)
TEST(->() { Sequencer.WS_next(@sequence, "begin", :id3) }, [], nil)
#TEST(``(Sequencer::WS_next(sequence, "ws_start", `next)), [], nil);
# TEST(``(Sequencer::WS_next(sequence, "ws_start", `next)), [], nil);
TEST(->() { Sequencer.WS_next(@sequence, "decide", :yes) }, [], nil)
TEST(->() { Sequencer.WS_next(@sequence, "decide", :no) }, [], nil)
TEST(->() { Sequencer.WS_next(@sequence, "end", :finish) }, [], nil)
Expand Down
2 changes: 1 addition & 1 deletion library/types/src/modules/Address.rb
Expand Up @@ -76,7 +76,7 @@ def Check(address)
# Describe a valid MAC address
# @return [String] description of a valid MAC address
def ValidMAC
#describe valid MAC address
# describe valid MAC address
_(
"A valid MAC address consists of six pairs of hexadecimal\ndigits separated by colons."
)
Expand Down

0 comments on commit 4a9a454

Please sign in to comment.