Skip to content

Commit

Permalink
fix comment annotiations format
Browse files Browse the repository at this point in the history
  • Loading branch information
jreidinger committed Jan 14, 2015
1 parent 7e33b33 commit bf25641
Show file tree
Hide file tree
Showing 18 changed files with 27 additions and 35 deletions.
5 changes: 0 additions & 5 deletions .rubocop.yml
Expand Up @@ -64,11 +64,6 @@ Style/AsciiComments:
Style/ClassAndModuleCamelCase:
Enabled: false

# Offense count: 27
# Configuration parameters: Keywords.
Style/CommentAnnotation:
Enabled: false

# Offense count: 1
# Cop supports --auto-correct.
Style/DeprecatedHashMethods:
Expand Down
6 changes: 3 additions & 3 deletions library/control/src/modules/ProductControl.rb
Expand Up @@ -305,7 +305,7 @@ def ReadControlFile(controlfile)
end
end

# FIXME would be nice if it could be done generic way
# FIXME: would be nice if it could be done generic way
if Ops.greater_than(
Builtins.size(
Ops.get_list(@productControl, ["partitioning", "partitions"], [])
Expand Down Expand Up @@ -558,7 +558,7 @@ def PrepareScripts(m)

# Get list of required files for the workflow.
# @return [Array<String>] Required files list.
# TODO FIXME: this function seems to be unused, remove it?
# FIXME: this function seems to be unused, remove it?
def RequiredFiles(stage, mode)
# Files needed during installation.
needed_client_files = []
Expand All @@ -581,7 +581,7 @@ def RequiredFiles(stage, mode)
client = Ops.add("inst_", Ops.get_string(m, "name", "dummy"))
end
end
# TODO FIXME: what about the ruby files?
# FIXME: what about the ruby files?
client = Ops.add(
Ops.add(Ops.add(Directory.clientdir, "/"), client),
".ycp"
Expand Down
2 changes: 1 addition & 1 deletion library/control/src/modules/WorkflowManager.rb
Expand Up @@ -532,7 +532,7 @@ def RemoveWorkflow(type, src_id, name)

# Removes all xml and ycp files from directory where
#
# TODO FIXME: this function seems to be unused, remove it?
# FIXME: this function seems to be unused, remove it?
def CleanWorkflowsDirectory
directory = GetWorkflowDirectory()
Builtins.y2milestone(
Expand Down
2 changes: 1 addition & 1 deletion library/cwm/src/modules/CWM.rb
Expand Up @@ -707,7 +707,7 @@ def validateWidgets(widgets, event)
def CreateWidgets(names, source)
names = deep_copy(names)
source = deep_copy(source)
ValidateMaps(source) # FIXME find better place
ValidateMaps(source) # FIXME: find better place
ret = Builtins.maplist(names) do |w|
m = Ops.get(source, w, {})
# leave add here in order to make a copy of the structure
Expand Down
4 changes: 2 additions & 2 deletions library/general/src/modules/ConfigHistory.rb
Expand Up @@ -361,7 +361,7 @@ def CheckAllFilesOutOfVersionControl
success = false
end
end
@commit_needed = true # TODO check if really necessary
@commit_needed = true # TODO: check if really necessary
Builtins.y2milestone("Finished successfuly: %1", success)
success
end
Expand Down Expand Up @@ -408,7 +408,7 @@ def RemoveDeletedFiles
success = false
end
end
@commit_needed = true # TODO check if really necessary
@commit_needed = true # TODO: check if really necessary
Builtins.y2milestone("Finished successfuly: %1", success)
success
end
Expand Down
2 changes: 1 addition & 1 deletion library/general/src/modules/Mode.rb
Expand Up @@ -129,7 +129,7 @@ def Initialize

# only use the /etc/install.inf agent when file is present
# and installation is being processed
# FIXME remove the part below and let it be set in clients
# FIXME: remove the part below and let it be set in clients
if @_mode == "installation" &&
SCR.Read(path(".target.size"), "/etc/install.inf") != -1

Expand Down
2 changes: 1 addition & 1 deletion library/gpg/src/modules/GPG.rb
Expand Up @@ -231,7 +231,7 @@ def CreateKey

if !text_mode
if Ops.less_than(SCR.Read(path(".target.size"), xterm), 0)
# TODO FIXME
# FIXME: do it
Report.Error(_("Xterm is missing, install xterm package."))
return false
end
Expand Down
6 changes: 3 additions & 3 deletions library/log/src/modules/ALog.rb
Expand Up @@ -28,7 +28,7 @@
#
# $Id$
# FATE#303700
# TODO stability tag.
# TODO: stability tag.
#
# <pre>
# ALog::Item("/etc/ntp.conf: added 'server ntp.example.org'");
Expand All @@ -50,7 +50,7 @@ def main
end

def doLog(type, msg)
# TODO make a separate log, this is just a prototype
# TODO: make a separate log, this is just a prototype
Builtins.y2internal("{%1} %2", type, msg)

nil
Expand Down Expand Up @@ -79,7 +79,7 @@ def Note(msg)
end

def uiInput(label)
# TODO more lines?
# TODO: more lines?
d = VBox(
InputField(Id(:val), label, ""),
ButtonBox(
Expand Down
2 changes: 1 addition & 1 deletion library/network/src/modules/CWMFirewallInterfaces.rb
Expand Up @@ -782,7 +782,7 @@ def CreateInterfacesWidget(settings)
# @return [Symbol] return value of the dialog
def DisplayDetailsPopup(settings)
settings = deep_copy(settings)
# FIXME breaks help if run in dialog with Tab!!!!!!
# FIXME: breaks help if run in dialog with Tab!!!!!!
# settings stack must be created in CWM::Run
w = CWM.CreateWidgets(
["firewall_ifaces"],
Expand Down
3 changes: 1 addition & 2 deletions library/network/src/modules/NetworkService.rb
Expand Up @@ -425,8 +425,7 @@ def stop_service(service)
return if !service

if service == :wicked
# FIXME:
# you really need to use 'wickedd'. Moreover kill action do not
# FIXME: you really need to use 'wickedd'. Moreover kill action do not
# kill all wickedd services - e.g. nanny, dhcp* ... stays running
# This needs to be clarified with wicked people.
# bnc#864619
Expand Down
2 changes: 1 addition & 1 deletion library/packages/src/modules/PackageCallbacks.rb
Expand Up @@ -2489,7 +2489,7 @@ def DoneScanDb(error, description)
end

def Authentication(url, msg, username, password)
# FIXME after SLE12 release
# FIXME: after SLE12 release
# The following 'if' block is a workaround for bnc#895719 that should be
# extracted to a proper private method (not sure if it will work as
# expected being a callback) and adapted to use normal _() instead of
Expand Down
2 changes: 1 addition & 1 deletion library/packages/src/modules/Product.rb
Expand Up @@ -97,7 +97,7 @@ def FindBaseProducts
products = Pkg.ResolvableProperties("", :product, "") || []

# For all (not only base) products
# TODO FIXME: filling release notes is a nasty side effect of searching the base product,
# FIXME: filling release notes is a nasty side effect of searching the base product,
# it should be handled separately...
required_status = use_installed_products? ? :installed : :selected
fill_up_relnotes(products.select{ |p| p["status"] == required_status })
Expand Down
2 changes: 1 addition & 1 deletion library/packages/src/modules/SignatureCheckDialogs.rb
Expand Up @@ -805,7 +805,7 @@ def ItemSignedWithUnknownSignature(item_type, item_name, key_id, dont_show_dialo
"\n" \
"Use it anyway?"
),
# TODO use something like "%1 from %2" and make it translatable
# TODO: use something like "%1 from %2" and make it translatable
repo_url != "" ?
Builtins.sformat("%1 (%2)", item_name, repo_url) :
item_name,
Expand Down
2 changes: 1 addition & 1 deletion library/packages/src/modules/SlideShow.rb
Expand Up @@ -136,7 +136,7 @@ def main

@current_slide_no = 0
@slide_start_time = 0
@slide_interval = 30 # FIXME constant
@slide_interval = 30 # FIXME: constant
@language = "en"
@widgets_created = false
@user_switched_to_details = false
Expand Down
4 changes: 2 additions & 2 deletions library/system/src/modules/Initrd.rb
Expand Up @@ -298,7 +298,7 @@ def Update
end

# Display error popup with log
# FIXME this is copy-paste from ../routines/popups.ycp
# FIXME: this is copy-paste from ../routines/popups.ycp
# @param [String] header string error header
# @param [String] log string logfile contents
def errorWithLogPopup(header, log)
Expand Down Expand Up @@ -377,7 +377,7 @@ def Write
"/usr/bin/touch /etc/sysconfig/bootloader"
)

# TODO FIXME: the modules are not written, remove them completely,
# FIXME: the modules are not written, remove them completely,
# for now just log them without any change
mods = Builtins.mergestring(ListModules(), " ")
log.warn "Ignoring configured kernel modules: #{mods}" unless mods.empty?
Expand Down
4 changes: 2 additions & 2 deletions library/system/src/modules/Kernel.rb
Expand Up @@ -269,7 +269,7 @@ def GetVgaType
end

# Set the vga= kernel argument
# FIXME is heer because of bootloader module, should be removed
# FIXME: is heer because of bootloader module, should be removed
def SetVgaType(new_vga)
ParseInstallationKernelCmdline() if !@cmdline_parsed
@vgaType = new_vga
Expand All @@ -292,7 +292,7 @@ def GetCmdLine
end

# Set the kernel command line
# FIXME is heer because of bootloader module, should be removed
# FIXME: is heer because of bootloader module, should be removed
def SetCmdLine(new_cmd_line)
ParseInstallationKernelCmdline() if !@cmdline_parsed
@cmdLine = new_cmd_line
Expand Down
6 changes: 2 additions & 4 deletions library/types/src/modules/URL.rb
Expand Up @@ -41,9 +41,7 @@ def main
Yast.import "IP"
Yast.import "URLRecode"

# TODO:
# - read URI(3)
# - esp. compare the regex mentioned in the URI(3) with ours:
# TODO: read URI(3), esp. compare the regex mentioned in the URI(3) with ours:
# my($scheme, $authority, $path, $query, $fragment) =
# $uri =~ m|^(?:([^:/?#]+):)?(?://([^/?#]*))?([^?#]*)(?:\?([^#]*))?(?:#(.*))?|;

Expand Down Expand Up @@ -218,7 +216,7 @@ def Parse(url)
Ops.get_string(rawtokens, 2, ""),
# 0,1,2,3: user:pass@
# 4,5,6,7: hostname|[xxx]
# FIXME "(([^:@]+)|(\\[([^]]+)\\]))" +
# FIXME: "(([^:@]+)|(\\[([^]]+)\\]))" +
# 8,9: port
"^" \
"(([^@:]+)(:([^@:]+))?@)?" \
Expand Down
6 changes: 3 additions & 3 deletions library/types/test/ip_test.rb
Expand Up @@ -88,9 +88,9 @@
"127.0.0.1",
"1:2:3:4:5:6:7:127.0.0.1",
"1:2:3::6:7:8:127.0.0.1",
#FIXME deprecated syntax, so we should handle it like invalid "::127.0.0.1",
#FIXME deprecated syntax, so we should handle it invalid "::FFFF:127.0.0.1",
#FIXME insufficient regex for ipv4 included in ipv6 "1:2:3:4:5:6:127.0.0.256"
#FIXME: deprecated syntax, so we should handle it like invalid "::127.0.0.1",
#FIXME: deprecated syntax, so we should handle it invalid "::FFFF:127.0.0.1",
#FIXME: insufficient regex for ipv4 included in ipv6 "1:2:3:4:5:6:127.0.0.256"
]

INVALID_IP6S.each do |invalid_ip6|
Expand Down

0 comments on commit bf25641

Please sign in to comment.