Revision a10caf87

b/autotools/build-bash-completion
236 236
    sw.DecIndent()
237 237
  sw.Write("}")
238 238

  
239
  # Params: <compgen options>
240
  # Result variable: $COMPREPLY
241
  sw.Write("_ganeti_compgen() {")
242
  sw.IncIndent()
243
  try:
244
    sw.Write("""COMPREPLY=( $(compgen "$@") )""")
245
    sw.Write("_ganeti_dbglog COMPREPLY=\"${COMPREPLY[@]}\"")
246
  finally:
247
    sw.DecIndent()
248
  sw.Write("}")
249

  
239 250

  
240 251
def WriteCompReply(sw, args, cur="\"$cur\""):
241
  sw.Write("""COMPREPLY=( $(compgen %s -- %s) )""", args, cur)
242
  sw.Write("_ganeti_dbglog COMPREPLY=\"${COMPREPLY[@]}\"")
252
  sw.Write("_ganeti_compgen %s -- %s", args, cur)
243 253
  sw.Write("return")
244 254

  
245 255

  

Also available in: Unified diff