画像処理のサンプルのusb-camera.launchを行っても画面が真っ黒です。

1,741 views
Skip to first unread message

yuto inagaki

unread,
Nov 19, 2012, 10:26:51 AM11/19/12
to rtm-ros-...@googlegroups.com
夜遅くに失礼申し上げます。
機械情報工学科3年の稲垣です。

今更で申し訳ないのですが、画像処理サンプルのページにある
ひとつめの準備のサンプル(カメラ画像を表示するだけ)を実行したところ、なにも表示されず、画面だけが立ち上がります。

使用しているカメラは、機械情報の演習で貸し出していただいてるUSBカメラです。

最後に実行したときのログをつけさせていただいております。

わからないなりに、
ERROR: cannot launch node of type [uvc_camera/camera_node]: uvc_camera
ではなかろうかと、
roswikiを見たところパッケージらしいので
rospack find uvc_cameraを行ったのですが、何も出ませんでした。
roslocate info uvc_cameraで

mechuser@UoT-IST-Ub:~/ros/fuerte$ roslocate info uvc_camera
- git:
    local-name: camera_umd
    meta:
      repo-name: umd-ros-pkg
    version: master
となったのですが、
これを入れればよろしいのでしょうか?
もし、入れればよい場合、どのように打てばいいのでしょうか。
的外れなことを考えているかもしれませんが、
よろしくお願いします。

mechuser@UoT-IST-Ub:~/ros/fuerte$ roslaunch roseus_tutorials usb-camera.launch 
... logging to /home/mechuser/.ros/log/695918be-324b-11e2-af93-0022fb92479e/roslaunch-UoT-IST-Ub-1045.log
Checking log directory for disk usage. This may take awhile.
Press Ctrl-C to interrupt
Done checking log file disk usage. Usage is <1GB.

started roslaunch server http://UoT-IST-Ub:42508/

SUMMARY
========

PARAMETERS
 * /rosdistro
 * /rosversion
 * /uvc_camera/camera_info_url
 * /uvc_camera/device
 * /uvc_camera/fps
 * /uvc_camera/frame_id
 * /uvc_camera/height
 * /uvc_camera/width

NODES
  /
    image_proc (image_proc/image_proc)
    uvc_camera (uvc_camera/camera_node)

WARNING: unrecognized tag sphinxdoc
ROS_MASTER_URI=http://localhost:11311

core service [/rosout] found
ERROR: cannot launch node of type [uvc_camera/camera_node]: uvc_camera
ROS path [0]=/opt/ros/fuerte/share/ros
ROS path [1]=/home/mechuser/ros/fuerte/stacks/
ROS path [2]=/home/mechuser/ros/fuerte/webots-ros-pkg
ROS path [3]=/home/mechuser/ros/fuerte/turtlebot
ROS path [4]=/home/mechuser/ros/fuerte/multimaster_experimental
ROS path [5]=/home/mechuser/ros/fuerte/ccny-vision
ROS path [6]=/home/mechuser/ros/fuerte/ua-ros-pkg
ROS path [7]=/home/mechuser/ros/fuerte/tum-ros-pkg
ROS path [8]=/home/mechuser/ros/fuerte/wg-ros-pkg-cturtle/sandbox/checkerboard_pose
ROS path [9]=/home/mechuser/ros/fuerte/wg-ros-pkg-cturtle/vision
ROS path [10]=/home/mechuser/ros/fuerte/cmu-ros-pkg
ROS path [11]=/home/mechuser/ros/fuerte/ros-pkg-git/kinect
ROS path [12]=/home/mechuser/ros/fuerte/stacks/camera1394
ROS path [13]=/home/mechuser/ros/fuerte/umd-ros-pkg/camera_umd
ROS path [14]=/home/mechuser/ros/fuerte/rtm-ros-robotics/agentsystem_ros_tutorials
ROS path [15]=/home/mechuser/ros/fuerte/rtm-ros-robotics/rtmros_common
ROS path [16]=/opt/ros/electric/stacks
ROS path [17]=/opt/ros/electric/ros
ROS path [18]=/home/mechuser/ros/fuerte/jsk-ros-pkg
ROS path [19]=/opt/ros/fuerte/stacks
ROS path [20]=/opt/ros/fuerte/share
ROS path [21]=/opt/ros/fuerte/share/ros
ROS path [22]=/home/mechuser/ros/fuerte/jsk-ros-pkg/
process[image_proc-2]: started with pid [1072]
[ WARN] [1353337845.856062652]: Started in the global namespace! This is probably wrong. Start image_proc in the camera namespace.
Example command-line usage:
$ ROS_NAMESPACE=my_camera rosrun image_proc image_proc
[ WARN] [1353337847.219620000]: The input topic '/image_raw' is not yet advertised
[ WARN] [1353337847.219718197]: The input topic '/camera_info' is not yet advertised


Yohei Kakiuchi

unread,
Nov 19, 2012, 10:37:50 AM11/19/12
to rtm-ros-...@googlegroups.com
ここのページを見ながらインストールしたと思います。
http://code.google.com/p/rtm-ros-robotics/wiki/ROS_Install

cd ~/ros/fuerte して
ls . するとどれぐらいディレクトリがあるでしょうか?

そこに、umd-ros-pkg が無ければ、以下のコマンドをしてみて、もう一度umd-ros-pkgがあるか確かめてみてください。
rosws merge http://rtm-ros-robotics.googlecode.com/svn/tags/latest/agentsystem_ros_tutorials/rtm-ros-robotics.rosinstall
rosws update

umd-ros-pkg がある場合は、
source ~/ros/fuerte/setup.bash して、 rospack find uvc_camera してみてください。
このとき、uvc_cameraがあれば、.bashrc に source ~/ros/fuerte/setup.bash を追加してください。

2012年11月20日 0:26 yuto inagaki <yuto.i...@gmail.com>:

> --
> このメールは Google グループのグループ「rtm-ros-robotics」の登録者に送られています。
> このディスカッションをウェブ上で閲覧するには、https://groups.google.com/d/msg/rtm-ros-robotics/-/UpgZZr3F3aMJ
> にアクセスしてください。
> このグループに投稿するには、rtm-ros-...@googlegroups.com にメールを送信してください。
> このグループから退会するには、rtm-ros-roboti...@googlegroups.com にメールを送信してください。
> 詳細については、http://groups.google.com/group/rtm-ros-robotics?hl=ja
> からこのグループにアクセスしてください。

yuto inagaki

unread,
Nov 19, 2012, 10:49:05 AM11/19/12
to rtm-ros-...@googlegroups.com
垣内様

稲垣です。
夜分遅くに
迅速なご返信ありがとうございます!

mechuser@UoT-IST-Ub:~/ros/fuerte$ ls .
#.rosinstall#  http:                     ros-pkg-git       setup.sh   tum-ros-pkg  umd-ros-pkg
ccny-vision    jsk-ros-pkg               rtm-ros-robotics  setup.zsh  turtlebot    webots-ros-pkg
cmu-ros-pkg    multimaster_experimental  setup.bash        stacks     ua-ros-pkg   wg-ros-pkg-cturtle

のようになっておりまして、
umd-ros-pkgなるものがありました。

あったのですが、
mechuser@UoT-IST-Ub:~/ros/fuerte$ source ~/ros/fuerte/setup.bash 
mechuser@UoT-IST-Ub:~/ros/fuerte$ rospack find uvc_camera
[rospack] Error: stack/package uvc_camera not found

となってしまっております。
また念のため.bashrcを確認しましたところ、すでに登録しておりました。
おそらくゼミのときに追加したと思います。

umd-ros-pkgの中を確認したところ
何もありませんでした。

この後は、先ほどの、rosws merge以下と、rosws updateを行えばよいでしょうか。
お忙しい中、大変恐縮ですが、
よろしくお願いいたします。




2012年11月20日火曜日 0時37分53秒 UTC+9 垣内(JSK):

> このグループに投稿するには、rtm-ros-robo...@googlegroups.com にメールを送信してください。
> このグループから退会するには、rtm-ros-robotics+unsubscribe@googlegroups.com にメールを送信してください。
> 詳細については、http://groups.google.com/group/rtm-ros-robotics?hl=ja
> からこのグループにアクセスしてください。

Yohei Kakiuchi

unread,
Nov 19, 2012, 10:57:37 AM11/19/12
to rtm-ros-...@googlegroups.com

そうですね。やってみて下さい。

mergeは何回やっても、重複したときは何もしないので問題ないです。
updateはエラーが出るかもしれないので、出てくる文字に注目してください。

2012/11/20 0:49 "yuto inagaki" <yuto.i...@gmail.com>:
このディスカッションをウェブ上で閲覧するには、https://groups.google.com/d/msg/rtm-ros-robotics/-/96iaEyXPA24J にアクセスしてください。
このグループに投稿するには、rtm-ros-...@googlegroups.com にメールを送信してください。
このグループから退会するには、rtm-ros-roboti...@googlegroups.com にメールを送信してください。
詳細については、http://groups.google.com/group/rtm-ros-robotics?hl=ja からこのグループにアクセスしてください。

yuto inagaki

unread,
Nov 19, 2012, 11:12:34 AM11/19/12
to rtm-ros-...@googlegroups.com
稲垣です。
ありがとうございます。

まずmergeの方を実行しました。
Merge caused no change, matching elements already exist
となったので、
とくに問題なかったのですが、
updateを行ってみたところ
以下のように出ている箇所がありました。

[umd-ros-pkg/camera_umd] Installing http://ram.umd.edu/git/ros/camera_umd.git (version master) to /home/mechuser/ros/fuerte/umd-ros-pkg/camera_umd
WARNING [vcstools] Command failed: 'git clone --recursive http://ram.umd.edu/git/ros/camera_umd.git /home/mechuser/ros/fuerte/umd-ros-pkg/camera_umd'
 errcode: 128:
fatal: failed to open '/home/mechuser/ros/fuerte/http://ram.umd.edu/git/ros/camera_umd.git/objects': No such file or directory


と、以下です。

[webots-ros-pkg] Done.
Exception caught during install: Error processing 'umd-ros-pkg/camera_umd' : [umd-ros-pkg/camera_umd] Checkout of http://ram.umd.edu/git/ros/camera_umd.git version master into /home/mechuser/ros/fuerte/umd-ros-pkg/camera_umd failed.

ERROR: Error processing 'umd-ros-pkg/camera_umd' : [umd-ros-pkg/camera_umd] Checkout of http://ram.umd.edu/git/ros/camera_umd.git version master into /home/mechuser/ros/fuerte/umd-ros-pkg/camera_umd failed.


岡田先生がゼミで、常にすべてのログを載せるようにおっしゃっていたので、
その他の部分も最後にのさせていただきます。

今回、僕の方で何をすればよいかerrorを読んでも
わかりませんでした。申し訳ありません。
よろしくお願いします。

mechuser@UoT-IST-Ub:~/ros/fuerte$ rosws update
[jsk-ros-pkg] Updating /home/mechuser/ros/fuerte/jsk-ros-pkg
A    /home/mechuser/ros/fuerte/jsk-ros-pkg/roseus_tutorials/src/subscribe-pointcloud.l
U    /home/mechuser/ros/fuerte/jsk-ros-pkg/roseus_tutorials/launch/tabletop-object-detector.launch
U    /home/mechuser/ros/fuerte/jsk-ros-pkg/roseus_tutorials/launch/tabletop-object-detector.vcg
U    /home/mechuser/ros/fuerte/jsk-ros-pkg/pr2eus/robot-interface.l
U    /home/mechuser/ros/fuerte/jsk-ros-pkg/pr2eus_tutorials/euslisp/pr2main.l
A    /home/mechuser/ros/fuerte/jsk-ros-pkg/pr2eus_tutorials/euslisp/tabletop-sample.l
U    /home/mechuser/ros/fuerte/jsk-ros-pkg/pr2eus_tutorials/euslisp/arm-navigation-sample.l
U    /home/mechuser/ros/fuerte/jsk-ros-pkg/pr2eus_tutorials/scripts/start_laser.py
A    /home/mechuser/ros/fuerte/jsk-ros-pkg/pr2eus_tutorials/launch/pr2_interactive_manipulation_sim.launch
A    /home/mechuser/ros/fuerte/jsk-ros-pkg/pr2eus_tutorials/launch/pr2_tabletop_sim.vcg
A    /home/mechuser/ros/fuerte/jsk-ros-pkg/pr2eus_tutorials/launch/spawn_objects.launch
A    /home/mechuser/ros/fuerte/jsk-ros-pkg/pr2eus_tutorials/launch/pr2_gazebo_objects.launch
A    /home/mechuser/ros/fuerte/jsk-ros-pkg/pr2eus_tutorials/launch/pr2_tabletop_sim.launch
U    /home/mechuser/ros/fuerte/jsk-ros-pkg/jsk_android_apps_api9/jsk_android_gui/src/ros/android/jskandroidgui/SensorImageViewInfo.java
U    /home/mechuser/ros/fuerte/jsk-ros-pkg/jsk_android_apps_api9/jsk_android_gui/src/ros/android/jskandroidgui/JskAndroidGui.java
U    /home/mechuser/ros/fuerte/jsk-ros-pkg/jsk_android_apps_api9/jsk_android_gui/res/menu/jsk_android_gui.xml
U    /home/mechuser/ros/fuerte/jsk-ros-pkg/jsk_android_apps_api9/jsk_android_gui/AndroidManifest.xml
U    /home/mechuser/ros/fuerte/jsk-ros-pkg/jsk_maps/raw_maps/eng2-7f-0.05.pgm
A    /home/mechuser/ros/fuerte/jsk-ros-pkg/jsk_smart_apps/jsk_smart_gui/src/emergency_stop.l
U    /home/mechuser/ros/fuerte/jsk-ros-pkg/jsk_smart_apps/android_camera_viewer/AndroidManifest.xml
U    /home/mechuser/ros/fuerte/jsk-ros-pkg/jsk_smart_apps/android_camera_viewer/src/org/ros/android/android_camera_viewer/MainActivity.java
A    /home/mechuser/ros/fuerte/jsk-ros-pkg/jsk_smart_apps/android_camera_viewer/src/org/ros/android/android_camera_viewer/AndroidAudioRecordService.java
A    /home/mechuser/ros/fuerte/jsk-ros-pkg/jsk_smart_apps/android_camera_viewer/src/org/ros/android/android_camera_viewer/AndroidAudioRecordNode.java
U    /home/mechuser/ros/fuerte/jsk-ros-pkg/jsk_smart_apps/android_voice_message/src/org/ros/android/android_voice_message/AndroidVoiceMessageNode.java
U    /home/mechuser/ros/fuerte/jsk-ros-pkg/jsk_smart_apps/android_voice_message/src/org/ros/android/android_voice_message/MainActivity.java
U    /home/mechuser/ros/fuerte/jsk-ros-pkg/jsk_smart_apps/android_voice_message/src/org/ros/android/android_voice_message/AndroidVoiceService.java
A    /home/mechuser/ros/fuerte/jsk-ros-pkg/jsk_smart_apps/android_voice_message/res/drawable/mike.png
U    /home/mechuser/ros/fuerte/jsk-ros-pkg/roseus/euslisp/actionlib-commstate.l
U    /home/mechuser/ros/fuerte/jsk-ros-pkg/roseus/euslisp/roseus-utils.l
U    /home/mechuser/ros/fuerte/jsk-ros-pkg/jsk_ros_patch/image_view2/image_view2.cpp
U    /home/mechuser/ros/fuerte/jsk-ros-pkg/jsk_ros_patch/image_view2/msg/ImageMarker2.msg
A    /home/mechuser/ros/fuerte/jsk-ros-pkg/jsk_ros_patch/image_view2/msg/PointArrayStamped.msg
U    /home/mechuser/ros/fuerte/jsk-ros-pkg/jsk_ros_patch/image_view2/test-imageview2.l
U    /home/mechuser/ros/fuerte/jsk-ros-pkg/jsk_pr2_startup/jsk_pr2_sensors/tilt_scan_cloud.launch
U    /home/mechuser/ros/fuerte/jsk-ros-pkg/jsk_pr2_startup/jsk_pr2_sensors/collision_map_sources_laser.yaml
A    /home/mechuser/ros/fuerte/jsk-ros-pkg/jsk_pr2_startup/jsk_pr2_sensors/jsk_pr2_tilt_laser_pipeline.dot
U    /home/mechuser/ros/fuerte/jsk-ros-pkg/jsk_pr2_startup/jsk_pr2_sensors/tablet_startup.launch
A    /home/mechuser/ros/fuerte/jsk-ros-pkg/jsk_pr2_startup/jsk_pr2_sensors/openni_tracker.launch
U    /home/mechuser/ros/fuerte/jsk-ros-pkg/jsk_pr2_startup/jsk_pr2_move_base/pr2_teleop_general_joystick.launch
U    /home/mechuser/ros/fuerte/jsk-ros-pkg/jsk_pr2_startup/pr2.launch
U    /home/mechuser/ros/fuerte/jsk-ros-pkg/jsk_pcl_ros/sample/color_filter_sample.launch
U    /home/mechuser/ros/fuerte/jsk-ros-pkg/jsk.rosbuild

外部項目を '/home/mechuser/ros/fuerte/jsk-ros-pkg/euslisp/jskeus' に取得しています
D    /home/mechuser/ros/fuerte/jsk-ros-pkg/euslisp/jskeus/irteus/PQP/Linux
D    /home/mechuser/ros/fuerte/jsk-ros-pkg/euslisp/jskeus/irteus/PQP/Cygwin
D    /home/mechuser/ros/fuerte/jsk-ros-pkg/euslisp/jskeus/irteus/PQP/Darwin
D    /home/mechuser/ros/fuerte/jsk-ros-pkg/euslisp/jskeus/irteus/PQP/Linux64
U    /home/mechuser/ros/fuerte/jsk-ros-pkg/euslisp/jskeus/irteus/PQP/Makefile

外部項目を '/home/mechuser/ros/fuerte/jsk-ros-pkg/euslisp/jskeus/eus/lisp' に取得しています
U    /home/mechuser/ros/fuerte/jsk-ros-pkg/euslisp/jskeus/eus/lisp/c/intern.c
U    /home/mechuser/ros/fuerte/jsk-ros-pkg/euslisp/jskeus/eus/lisp/geo/geobody.l
U    /home/mechuser/ros/fuerte/jsk-ros-pkg/euslisp/jskeus/eus/lisp/geo/geopack.l
外部項目をリビジョン 587 に更新しました。


外部項目を '/home/mechuser/ros/fuerte/jsk-ros-pkg/euslisp/jskeus/eus/lib' に取得しています
外部項目をリビジョン 587 に更新しました。


外部項目を '/home/mechuser/ros/fuerte/jsk-ros-pkg/euslisp/jskeus/eus/lib/llib' に取得しています
外部項目をリビジョン 587 に更新しました。

リビジョン 863 に更新しました。
リビジョン 3627 に更新しました。
[jsk-ros-pkg] Done.
[rtm-ros-robotics/rtmros_common] Updating /home/mechuser/ros/fuerte/rtm-ros-robotics/rtmros_common
リビジョン 3229 です。
[rtm-ros-robotics/rtmros_common] Done.
[rtm-ros-robotics/agentsystem_ros_tutorials] Updating /home/mechuser/ros/fuerte/rtm-ros-robotics/agentsystem_ros_tutorials
C    /home/mechuser/ros/fuerte/rtm-ros-robotics/agentsystem_ros_tutorials/move_base_stage_tutorial/world/willow.world
リビジョン 3229 に更新しました。
Summary of conflicts:
  Text conflicts: 1
[rtm-ros-robotics/agentsystem_ros_tutorials] Done.
[umd-ros-pkg/camera_umd] Installing http://ram.umd.edu/git/ros/camera_umd.git (version master) to /home/mechuser/ros/fuerte/umd-ros-pkg/camera_umd
WARNING [vcstools] Command failed: 'git clone --recursive http://ram.umd.edu/git/ros/camera_umd.git /home/mechuser/ros/fuerte/umd-ros-pkg/camera_umd'
 errcode: 128:
fatal: failed to open '/home/mechuser/ros/fuerte/http://ram.umd.edu/git/ros/camera_umd.git/objects': No such file or directory
[/vcstools]
[stacks/camera1394] Updating /home/mechuser/ros/fuerte/stacks/camera1394
リビジョン 40280 です。
[stacks/camera1394] Done.
[ros-pkg-git/kinect] Updating /home/mechuser/ros/fuerte/ros-pkg-git/kinect
[ros-pkg-git/kinect] Done.
[cmu-ros-pkg] Updating /home/mechuser/ros/fuerte/cmu-ros-pkg
リビジョン 442 です。
[cmu-ros-pkg] Done.
[wg-ros-pkg-cturtle/vision] Updating /home/mechuser/ros/fuerte/wg-ros-pkg-cturtle/vision
リビジョン 55197 です。
[wg-ros-pkg-cturtle/vision] Done.
[wg-ros-pkg-cturtle/sandbox/checkerboard_pose] Updating /home/mechuser/ros/fuerte/wg-ros-pkg-cturtle/sandbox/checkerboard_pose
リビジョン 55197 です。
[wg-ros-pkg-cturtle/sandbox/checkerboard_pose] Done.
[tum-ros-pkg] Updating /home/mechuser/ros/fuerte/tum-ros-pkg
リビジョン 1010 です。
[tum-ros-pkg] Done.
[ua-ros-pkg] Updating /home/mechuser/ros/fuerte/ua-ros-pkg
リビジョン 1653 です。
[ua-ros-pkg] Done.
[ccny-vision] Updating /home/mechuser/ros/fuerte/ccny-vision
[ccny-vision] Done.
[multimaster_experimental] Updating /home/mechuser/ros/fuerte/multimaster_experimental
リビジョン 17262 です。
[multimaster_experimental] Done.
[turtlebot] Updating /home/mechuser/ros/fuerte/turtlebot
変更点を探索中
差分はありません
ファイル状態: 更新数 0、マージ数 0、削除数 0、衝突未解決数 0
[turtlebot] Done.
[webots-ros-pkg] Updating /home/mechuser/ros/fuerte/webots-ros-pkg
U    /home/mechuser/ros/fuerte/webots-ros-pkg/webots/webots_simulator/Makefile
リビジョン 16 に更新しました。
[webots-ros-pkg] Done.
Exception caught during install: Error processing 'umd-ros-pkg/camera_umd' : [umd-ros-pkg/camera_umd] Checkout of http://ram.umd.edu/git/ros/camera_umd.git version master into /home/mechuser/ros/fuerte/umd-ros-pkg/camera_umd failed.

ERROR: Error processing 'umd-ros-pkg/camera_umd' : [umd-ros-pkg/camera_umd] Checkout of http://ram.umd.edu/git/ros/camera_umd.git version master into /home/mechuser/ros/fuerte/umd-ros-pkg/camera_umd failed.

mechuser@UoT-IST-Ub:~/ros/fuerte$ 


2012年11月20日火曜日 0時57分38秒 UTC+9 垣内(JSK):

> このグループに投稿するには、rtm-ros-robotics@googlegroups.com にメールを送信してください。


> このグループから退会するには、rtm-ros-robotics+unsubscribe@googlegroups.com にメールを送信してください。
> 詳細については、http://groups.google.com/group/rtm-ros-robotics?hl=ja
> からこのグループにアクセスしてください。

Yohei Kakiuchi

unread,
Nov 19, 2012, 11:56:05 AM11/19/12
to rtm-ros-...@googlegroups.com
メッセージからすると他のパッケージはちゃんとインストールされているようです。
cd ~/ros/fuerte; rm -rf umd-ros-pkg
して、umd-ros-pkgディレクトリ全体を消してから、rosws update をやってみたらどうなるでしょうか。

2012年11月20日 1:12 yuto inagaki <yuto.i...@gmail.com>:

>>>> > このグループに投稿するには、rtm-ros-...@googlegroups.com にメールを送信してください。
>>>> > このグループから退会するには、rtm-ros-roboti...@googlegroups.com


>>>> > にメールを送信してください。
>>>> > 詳細については、http://groups.google.com/group/rtm-ros-robotics?hl=ja
>>>> > からこのグループにアクセスしてください。
>>>
>>> --
>>> このメールは Google グループのグループ「rtm-ros-robotics」の登録者に送られています。
>>>
>>> このディスカッションをウェブ上で閲覧するには、https://groups.google.com/d/msg/rtm-ros-robotics/-/96iaEyXPA24J
>>> にアクセスしてください。

>>> このグループに投稿するには、rtm-ros-...@googlegroups.com にメールを送信してください。
>>> このグループから退会するには、rtm-ros-roboti...@googlegroups.com


>>> にメールを送信してください。
>>> 詳細については、http://groups.google.com/group/rtm-ros-robotics?hl=ja
>>> からこのグループにアクセスしてください。
>
> --
> このメールは Google グループのグループ「rtm-ros-robotics」の登録者に送られています。

> このディスカッションをウェブ上で閲覧するには、https://groups.google.com/d/msg/rtm-ros-robotics/-/rj7mfpLznvAJ
> にアクセスしてください。
>
> このグループに投稿するには、rtm-ros-...@googlegroups.com にメールを送信してください。
> このグループから退会するには、rtm-ros-roboti...@googlegroups.com にメールを送信してください。
> 詳細については、http://groups.google.com/group/rtm-ros-robotics?hl=ja
> からこのグループにアクセスしてください。

yuto inagaki

unread,
Nov 19, 2012, 12:07:24 PM11/19/12
to rtm-ros-...@googlegroups.com
夜遅くまでありがとうございます。

削除してからまた実行しました。
なぜ失敗しているか僕の方ではよくわかりませんが、
git cloneはこのパソコンで使えてます。

お時間があれば、
よろしくお願いします。


mechuser@UoT-IST-Ub:~/ros/fuerte$ ls
#.rosinstall#  http:                     ros-pkg-git       setup.sh   tum-ros-pkg  umd-ros-pkg
ccny-vision    jsk-ros-pkg               rtm-ros-robotics  setup.zsh  turtlebot    webots-ros-pkg
cmu-ros-pkg    multimaster_experimental  setup.bash        stacks     ua-ros-pkg   wg-ros-pkg-cturtle

mechuser@UoT-IST-Ub:~/ros/fuerte$ rm -rf umd-ros-pkg/

mechuser@UoT-IST-Ub:~/ros/fuerte$ rosws update
[jsk-ros-pkg] Updating /home/mechuser/ros/fuerte/jsk-ros-pkg

外部項目を '/home/mechuser/ros/fuerte/jsk-ros-pkg/euslisp/jskeus' に取得しています

外部項目を '/home/mechuser/ros/fuerte/jsk-ros-pkg/euslisp/jskeus/eus/lisp' に取得しています
リビジョン 587 の外部項目です。


外部項目を '/home/mechuser/ros/fuerte/jsk-ros-pkg/euslisp/jskeus/eus/lib' に取得しています
リビジョン 587 の外部項目です。


外部項目を '/home/mechuser/ros/fuerte/jsk-ros-pkg/euslisp/jskeus/eus/lib/llib' に取得しています
リビジョン 587 の外部項目です。

リビジョン 863 です。
リビジョン 3627 です。
[jsk-ros-pkg] Done.
[rtm-ros-robotics/rtmros_common] Updating /home/mechuser/ros/fuerte/rtm-ros-robotics/rtmros_common
リビジョン 3229 です。
[rtm-ros-robotics/rtmros_common] Done.
[rtm-ros-robotics/agentsystem_ros_tutorials] Updating /home/mechuser/ros/fuerte/rtm-ros-robotics/agentsystem_ros_tutorials
リビジョン 3229 です。
リビジョン 16 です。
[webots-ros-pkg] Done.
Exception caught during install: Error processing 'umd-ros-pkg/camera_umd' : [umd-ros-pkg/camera_umd] Checkout of http://ram.umd.edu/git/ros/camera_umd.git version master into /home/mechuser/ros/fuerte/umd-ros-pkg/camera_umd failed.

ERROR: Error processing 'umd-ros-pkg/camera_umd' : [umd-ros-pkg/camera_umd] Checkout of http://ram.umd.edu/git/ros/camera_umd.git version master into /home/mechuser/ros/fuerte/umd-ros-pkg/camera_umd failed.

mechuser@UoT-IST-Ub:~/ros/fuerte$ 


2012年11月20日火曜日 1時56分06秒 UTC+9 垣内(JSK):

>>>> > このグループに投稿するには、rtm-ros-robo...@googlegroups.com にメールを送信してください。
>>>> > このグループから退会するには、rtm-ros-robotics+unsubscribe@googlegroups.com


>>>> > にメールを送信してください。
>>>> > 詳細については、http://groups.google.com/group/rtm-ros-robotics?hl=ja
>>>> > からこのグループにアクセスしてください。
>>>
>>> --
>>> このメールは Google グループのグループ「rtm-ros-robotics」の登録者に送られています。
>>>
>>> このディスカッションをウェブ上で閲覧するには、https://groups.google.com/d/msg/rtm-ros-robotics/-/96iaEyXPA24J
>>> にアクセスしてください。

>>> このグループに投稿するには、rtm-ros-robo...@googlegroups.com にメールを送信してください。
>>> このグループから退会するには、rtm-ros-robotics+unsubscribe@googlegroups.com


>>> にメールを送信してください。
>>> 詳細については、http://groups.google.com/group/rtm-ros-robotics?hl=ja
>>> からこのグループにアクセスしてください。
>
> --
> このメールは Google グループのグループ「rtm-ros-robotics」の登録者に送られています。
> このディスカッションをウェブ上で閲覧するには、https://groups.google.com/d/msg/rtm-ros-robotics/-/rj7mfpLznvAJ
> にアクセスしてください。
>

> このグループに投稿するには、rtm-ros-robo...@googlegroups.com にメールを送信してください。
> このグループから退会するには、rtm-ros-robotics+unsubscribe@googlegroups.com にメールを送信してください。
> 詳細については、http://groups.google.com/group/rtm-ros-robotics?hl=ja
> からこのグループにアクセスしてください。

Yohei Kakiuchi

unread,
Nov 19, 2012, 12:12:23 PM11/19/12
to rtm-ros-...@googlegroups.com
rosws --version と
which rosws の結果はどうなりますか?

2012年11月20日 2:07 yuto inagaki <yuto.i...@gmail.com>:

>> >>>> > このグループに投稿するには、rtm-ros-...@googlegroups.com にメールを送信してください。
>> >>>> > このグループから退会するには、rtm-ros-roboti...@googlegroups.com


>> >>>> > にメールを送信してください。
>> >>>> > 詳細については、http://groups.google.com/group/rtm-ros-robotics?hl=ja
>> >>>> > からこのグループにアクセスしてください。
>> >>>
>> >>> --
>> >>> このメールは Google グループのグループ「rtm-ros-robotics」の登録者に送られています。
>> >>>
>> >>>
>> >>> このディスカッションをウェブ上で閲覧するには、https://groups.google.com/d/msg/rtm-ros-robotics/-/96iaEyXPA24J
>> >>> にアクセスしてください。

>> >>> このグループに投稿するには、rtm-ros-...@googlegroups.com にメールを送信してください。
>> >>> このグループから退会するには、rtm-ros-roboti...@googlegroups.com


>> >>> にメールを送信してください。
>> >>> 詳細については、http://groups.google.com/group/rtm-ros-robotics?hl=ja
>> >>> からこのグループにアクセスしてください。
>> >
>> > --
>> > このメールは Google グループのグループ「rtm-ros-robotics」の登録者に送られています。
>> >
>> > このディスカッションをウェブ上で閲覧するには、https://groups.google.com/d/msg/rtm-ros-robotics/-/rj7mfpLznvAJ
>> > にアクセスしてください。
>> >

>> > このグループに投稿するには、rtm-ros-...@googlegroups.com にメールを送信してください。
>> > このグループから退会するには、rtm-ros-roboti...@googlegroups.com


>> > にメールを送信してください。
>> > 詳細については、http://groups.google.com/group/rtm-ros-robotics?hl=ja
>> > からこのグループにアクセスしてください。
>
> --
> このメールは Google グループのグループ「rtm-ros-robotics」の登録者に送られています。

> このディスカッションをウェブ上で閲覧するには、https://groups.google.com/d/msg/rtm-ros-robotics/-/PLHJC3epc34J
> にアクセスしてください。
>
> このグループに投稿するには、rtm-ros-...@googlegroups.com にメールを送信してください。
> このグループから退会するには、rtm-ros-roboti...@googlegroups.com にメールを送信してください。
> 詳細については、http://groups.google.com/group/rtm-ros-robotics?hl=ja
> からこのグループにアクセスしてください。

yuto inagaki

unread,
Nov 19, 2012, 12:15:46 PM11/19/12
to rtm-ros-...@googlegroups.com
mechuser@UoT-IST-Ub:~/ros/fuerte$ rosws --version
rosws: 0.6.20
vcstools:  0.1.24
SVN:       svn, バージョン 1.6.6 (r40053); 
Mercurial: Mercurial - 分散構成管理ツール(バージョン 1.4.3); 
Git:       1.7.0.4; 'reset --keep': False, submodules: True
Tar:       tarfile version: $Revision: 76386 $; 
Bzr:       Bazaar (bzr) 2.1.4; 

mechuser@UoT-IST-Ub:~/ros/fuerte$ which rosws
/usr/local/bin/rosws
mechuser@UoT-IST-Ub:~/ros/fuerte$ 

のようになりました。

2012年11月20日火曜日 2時12分26秒 UTC+9 垣内(JSK):

>> >>>> > このグループに投稿するには、rtm-ros-robo...@googlegroups.com にメールを送信してください。
>> >>>> > このグループから退会するには、rtm-ros-robotics+unsubscribe@googlegroups.com


>> >>>> > にメールを送信してください。
>> >>>> > 詳細については、http://groups.google.com/group/rtm-ros-robotics?hl=ja
>> >>>> > からこのグループにアクセスしてください。
>> >>>
>> >>> --
>> >>> このメールは Google グループのグループ「rtm-ros-robotics」の登録者に送られています。
>> >>>
>> >>>
>> >>> このディスカッションをウェブ上で閲覧するには、https://groups.google.com/d/msg/rtm-ros-robotics/-/96iaEyXPA24J
>> >>> にアクセスしてください。

>> >>> このグループに投稿するには、rtm-ros-robo...@googlegroups.com にメールを送信してください。
>> >>> このグループから退会するには、rtm-ros-robotics+unsubscribe@googlegroups.com


>> >>> にメールを送信してください。
>> >>> 詳細については、http://groups.google.com/group/rtm-ros-robotics?hl=ja
>> >>> からこのグループにアクセスしてください。
>> >
>> > --
>> > このメールは Google グループのグループ「rtm-ros-robotics」の登録者に送られています。
>> >
>> > このディスカッションをウェブ上で閲覧するには、https://groups.google.com/d/msg/rtm-ros-robotics/-/rj7mfpLznvAJ
>> > にアクセスしてください。
>> >

>> > このグループに投稿するには、rtm-ros-robo...@googlegroups.com にメールを送信してください。
>> > このグループから退会するには、rtm-ros-robotics+unsubscribe@googlegroups.com


>> > にメールを送信してください。
>> > 詳細については、http://groups.google.com/group/rtm-ros-robotics?hl=ja
>> > からこのグループにアクセスしてください。
>
> --
> このメールは Google グループのグループ「rtm-ros-robotics」の登録者に送られています。
> このディスカッションをウェブ上で閲覧するには、https://groups.google.com/d/msg/rtm-ros-robotics/-/PLHJC3epc34J
> にアクセスしてください。
>

> このグループに投稿するには、rtm-ros-robo...@googlegroups.com にメールを送信してください。
> このグループから退会するには、rtm-ros-robotics+unsubscribe@googlegroups.com にメールを送信してください。
> 詳細については、http://groups.google.com/group/rtm-ros-robotics?hl=ja
> からこのグループにアクセスしてください。

Yohei Kakiuchi

unread,
Nov 19, 2012, 12:30:49 PM11/19/12
to rtm-ros-...@googlegroups.com
すこし古いrosのインストールが残っているかもしれません。
/usr/local 以下のros関連のファイルを下のように消してもう一度やってみてください。

rm /usr/local/bin/ros*
rm /usr/local/lib/python*/dist-packages/ros*
rm /usr/local/lib/python*/dist-packages/vcstools*

2012年11月20日 2:15 yuto inagaki <yuto.i...@gmail.com>:

>> >> >>>> > このグループに投稿するには、rtm-ros-...@googlegroups.com にメールを送信してください。
>> >> >>>> > このグループから退会するには、rtm-ros-roboti...@googlegroups.com


>> >> >>>> > にメールを送信してください。
>> >> >>>> > 詳細については、http://groups.google.com/group/rtm-ros-robotics?hl=ja
>> >> >>>> > からこのグループにアクセスしてください。
>> >> >>>
>> >> >>> --
>> >> >>> このメールは Google グループのグループ「rtm-ros-robotics」の登録者に送られています。
>> >> >>>
>> >> >>>
>> >> >>>
>> >> >>> このディスカッションをウェブ上で閲覧するには、https://groups.google.com/d/msg/rtm-ros-robotics/-/96iaEyXPA24J
>> >> >>> にアクセスしてください。

>> >> >>> このグループに投稿するには、rtm-ros-...@googlegroups.com にメールを送信してください。
>> >> >>> このグループから退会するには、rtm-ros-roboti...@googlegroups.com


>> >> >>> にメールを送信してください。
>> >> >>> 詳細については、http://groups.google.com/group/rtm-ros-robotics?hl=ja
>> >> >>> からこのグループにアクセスしてください。
>> >> >
>> >> > --
>> >> > このメールは Google グループのグループ「rtm-ros-robotics」の登録者に送られています。
>> >> >
>> >> >
>> >> > このディスカッションをウェブ上で閲覧するには、https://groups.google.com/d/msg/rtm-ros-robotics/-/rj7mfpLznvAJ
>> >> > にアクセスしてください。
>> >> >

>> >> > このグループに投稿するには、rtm-ros-...@googlegroups.com にメールを送信してください。
>> >> > このグループから退会するには、rtm-ros-roboti...@googlegroups.com


>> >> > にメールを送信してください。
>> >> > 詳細については、http://groups.google.com/group/rtm-ros-robotics?hl=ja
>> >> > からこのグループにアクセスしてください。
>> >
>> > --
>> > このメールは Google グループのグループ「rtm-ros-robotics」の登録者に送られています。
>> >
>> > このディスカッションをウェブ上で閲覧するには、https://groups.google.com/d/msg/rtm-ros-robotics/-/PLHJC3epc34J
>> > にアクセスしてください。
>> >

>> > このグループに投稿するには、rtm-ros-...@googlegroups.com にメールを送信してください。
>> > このグループから退会するには、rtm-ros-roboti...@googlegroups.com


>> > にメールを送信してください。
>> > 詳細については、http://groups.google.com/group/rtm-ros-robotics?hl=ja
>> > からこのグループにアクセスしてください。
>
> --
> このメールは Google グループのグループ「rtm-ros-robotics」の登録者に送られています。

> このディスカッションをウェブ上で閲覧するには、https://groups.google.com/d/msg/rtm-ros-robotics/-/LHsPRKE7WzgJ
> にアクセスしてください。
>
> このグループに投稿するには、rtm-ros-...@googlegroups.com にメールを送信してください。
> このグループから退会するには、rtm-ros-roboti...@googlegroups.com にメールを送信してください。
> 詳細については、http://groups.google.com/group/rtm-ros-robotics?hl=ja
> からこのグループにアクセスしてください。

yuto inagaki

unread,
Nov 19, 2012, 12:54:53 PM11/19/12
to rtm-ros-...@googlegroups.com
削除を行いました。

mechuser@UoT-IST-Ub:~/ros/fuerte$ rosws --version
rosws: 0.6.20
vcstools:  0.1.24
SVN:       svn, バージョン 1.6.6 (r40053); 
Mercurial: Mercurial - 分散構成管理ツール(バージョン 1.4.3); 
Git:       1.7.0.4; 'reset --keep': False, submodules: True
Tar:       tarfile version: $Revision: 76386 $; 
Bzr:       Bazaar (bzr) 2.1.4; 

mechuser@UoT-IST-Ub:~/ros/fuerte$ which rosws
/usr/bin/rosws
のように変わりましたが、

Merge caused no change, matching elements already exist

であり、
updateもそのままのようです。
お時間があれば、
よろしくお願いします。

mechuser@UoT-IST-Ub:~/ros/fuerte$ rosws update
[jsk-ros-pkg] Updating /home/mechuser/ros/fuerte/jsk-ros-pkg





2012年11月20日火曜日 2時30分50秒 UTC+9 垣内(JSK):

>> >> >>>> > このグループに投稿するには、rtm-ros-robo...@googlegroups.com にメールを送信してください。
>> >> >>>> > このグループから退会するには、rtm-ros-robotics+unsubscribe@googlegroups.com


>> >> >>>> > にメールを送信してください。
>> >> >>>> > 詳細については、http://groups.google.com/group/rtm-ros-robotics?hl=ja
>> >> >>>> > からこのグループにアクセスしてください。
>> >> >>>
>> >> >>> --
>> >> >>> このメールは Google グループのグループ「rtm-ros-robotics」の登録者に送られています。
>> >> >>>
>> >> >>>
>> >> >>>
>> >> >>> このディスカッションをウェブ上で閲覧するには、https://groups.google.com/d/msg/rtm-ros-robotics/-/96iaEyXPA24J
>> >> >>> にアクセスしてください。

>> >> >>> このグループに投稿するには、rtm-ros-robo...@googlegroups.com にメールを送信してください。
>> >> >>> このグループから退会するには、rtm-ros-robotics+unsubscribe@googlegroups.com


>> >> >>> にメールを送信してください。
>> >> >>> 詳細については、http://groups.google.com/group/rtm-ros-robotics?hl=ja
>> >> >>> からこのグループにアクセスしてください。
>> >> >
>> >> > --
>> >> > このメールは Google グループのグループ「rtm-ros-robotics」の登録者に送られています。
>> >> >
>> >> >
>> >> > このディスカッションをウェブ上で閲覧するには、https://groups.google.com/d/msg/rtm-ros-robotics/-/rj7mfpLznvAJ
>> >> > にアクセスしてください。
>> >> >

>> >> > このグループに投稿するには、rtm-ros-robo...@googlegroups.com にメールを送信してください。
>> >> > このグループから退会するには、rtm-ros-robotics+unsubscribe@googlegroups.com


>> >> > にメールを送信してください。
>> >> > 詳細については、http://groups.google.com/group/rtm-ros-robotics?hl=ja
>> >> > からこのグループにアクセスしてください。
>> >
>> > --
>> > このメールは Google グループのグループ「rtm-ros-robotics」の登録者に送られています。
>> >
>> > このディスカッションをウェブ上で閲覧するには、https://groups.google.com/d/msg/rtm-ros-robotics/-/PLHJC3epc34J
>> > にアクセスしてください。
>> >

>> > このグループに投稿するには、rtm-ros-robo...@googlegroups.com にメールを送信してください。
>> > このグループから退会するには、rtm-ros-robotics+unsubscribe@googlegroups.com


>> > にメールを送信してください。
>> > 詳細については、http://groups.google.com/group/rtm-ros-robotics?hl=ja
>> > からこのグループにアクセスしてください。
>
> --
> このメールは Google グループのグループ「rtm-ros-robotics」の登録者に送られています。
> このディスカッションをウェブ上で閲覧するには、https://groups.google.com/d/msg/rtm-ros-robotics/-/LHsPRKE7WzgJ
> にアクセスしてください。
>

> このグループに投稿するには、rtm-ros-robo...@googlegroups.com にメールを送信してください。
> このグループから退会するには、rtm-ros-robotics+unsubscribe@googlegroups.com にメールを送信してください。
> 詳細については、http://groups.google.com/group/rtm-ros-robotics?hl=ja
> からこのグループにアクセスしてください。

Yohei Kakiuchi

unread,
Nov 19, 2012, 1:45:25 PM11/19/12
to rtm-ros-...@googlegroups.com
コマンド単体で成功するかな?

成功しないようなら、sudo apt-get update; sudo apt-get dist-upgrade git-core してみて、再挑戦。
あとは、.gitconfig に何か書いていないか。

2012年11月20日 2:54 yuto inagaki <yuto.i...@gmail.com>:

>> >> >> >>>> > このグループに投稿するには、rtm-ros-...@googlegroups.com
>> >> >> >>>> > にメールを送信してください。
>> >> >> >>>> > このグループから退会するには、rtm-ros-roboti...@googlegroups.com


>> >> >> >>>> > にメールを送信してください。
>> >> >> >>>> > 詳細については、http://groups.google.com/group/rtm-ros-robotics?hl=ja
>> >> >> >>>> > からこのグループにアクセスしてください。
>> >> >> >>>
>> >> >> >>> --
>> >> >> >>> このメールは Google グループのグループ「rtm-ros-robotics」の登録者に送られています。
>> >> >> >>>
>> >> >> >>>
>> >> >> >>>
>> >> >> >>>
>> >> >> >>> このディスカッションをウェブ上で閲覧するには、https://groups.google.com/d/msg/rtm-ros-robotics/-/96iaEyXPA24J
>> >> >> >>> にアクセスしてください。

>> >> >> >>> このグループに投稿するには、rtm-ros-...@googlegroups.com にメールを送信してください。
>> >> >> >>> このグループから退会するには、rtm-ros-roboti...@googlegroups.com


>> >> >> >>> にメールを送信してください。
>> >> >> >>> 詳細については、http://groups.google.com/group/rtm-ros-robotics?hl=ja
>> >> >> >>> からこのグループにアクセスしてください。
>> >> >> >
>> >> >> > --
>> >> >> > このメールは Google グループのグループ「rtm-ros-robotics」の登録者に送られています。
>> >> >> >
>> >> >> >
>> >> >> >
>> >> >> > このディスカッションをウェブ上で閲覧するには、https://groups.google.com/d/msg/rtm-ros-robotics/-/rj7mfpLznvAJ
>> >> >> > にアクセスしてください。
>> >> >> >

>> >> >> > このグループに投稿するには、rtm-ros-...@googlegroups.com にメールを送信してください。
>> >> >> > このグループから退会するには、rtm-ros-roboti...@googlegroups.com


>> >> >> > にメールを送信してください。
>> >> >> > 詳細については、http://groups.google.com/group/rtm-ros-robotics?hl=ja
>> >> >> > からこのグループにアクセスしてください。
>> >> >
>> >> > --
>> >> > このメールは Google グループのグループ「rtm-ros-robotics」の登録者に送られています。
>> >> >
>> >> >
>> >> > このディスカッションをウェブ上で閲覧するには、https://groups.google.com/d/msg/rtm-ros-robotics/-/PLHJC3epc34J
>> >> > にアクセスしてください。
>> >> >

>> >> > このグループに投稿するには、rtm-ros-...@googlegroups.com にメールを送信してください。
>> >> > このグループから退会するには、rtm-ros-roboti...@googlegroups.com


>> >> > にメールを送信してください。
>> >> > 詳細については、http://groups.google.com/group/rtm-ros-robotics?hl=ja
>> >> > からこのグループにアクセスしてください。
>> >
>> > --
>> > このメールは Google グループのグループ「rtm-ros-robotics」の登録者に送られています。
>> >
>> > このディスカッションをウェブ上で閲覧するには、https://groups.google.com/d/msg/rtm-ros-robotics/-/LHsPRKE7WzgJ
>> > にアクセスしてください。
>> >

>> > このグループに投稿するには、rtm-ros-...@googlegroups.com にメールを送信してください。
>> > このグループから退会するには、rtm-ros-roboti...@googlegroups.com


>> > にメールを送信してください。
>> > 詳細については、http://groups.google.com/group/rtm-ros-robotics?hl=ja
>> > からこのグループにアクセスしてください。
>
> --
> このメールは Google グループのグループ「rtm-ros-robotics」の登録者に送られています。

> このディスカッションをウェブ上で閲覧するには、https://groups.google.com/d/msg/rtm-ros-robotics/-/zDpkevrJc3cJ
> にアクセスしてください。
>
> このグループに投稿するには、rtm-ros-...@googlegroups.com にメールを送信してください。
> このグループから退会するには、rtm-ros-roboti...@googlegroups.com にメールを送信してください。
> 詳細については、http://groups.google.com/group/rtm-ros-robotics?hl=ja
> からこのグループにアクセスしてください。

yuto inagaki

unread,
Nov 19, 2012, 7:42:32 PM11/19/12
to rtm-ros-...@googlegroups.com

~/ros/fuerteで
を実行すると、
mechuser@UoT-IST-Ub:~/ros/fuerte$ git clone --recursive http://ram.umd.edu/git/ros/camera_umd.git
Initialized empty Git repository in /home/mechuser/ros/fuerte/camera_umd/.git/
fatal: failed to open '/home/mechuser/ros/fuerte/http://ram.umd.edu/git/ros/camera_umd.git/objects': No such file or directory
となってしまいます。

sudo apt-get update; sudo apt-get dist-upgrade git-core
をしたところ、かなり更新されたようです。

しかし、~/ros/fuerteで
を実行すると、
mechuser@UoT-IST-Ub:~/ros/fuerte$ git clone --recursive http://ram.umd.edu/git/ros/camera_umd.git
Initialized empty Git repository in /home/mechuser/ros/fuerte/camera_umd/.git/
fatal: failed to open '/home/mechuser/ros/fuerte/http://ram.umd.edu/git/ros/camera_umd.git/objects': No such file or directory
と表示されてしまい、
ホームディレクトリで行うと
Initialized empty Git repository in /home/mechuser/ros/fuerte/camera_umd/.git/
となりました。

rosws updateをホームディレクトリで行うと、
mechuser@UoT-IST-Ub:~$ rosws update
ERROR: Ambiguous workspace: ROS_WORKSPACE=/home/mechuser/ros/fuerte, /home/mechuser/.rosinstall

となってしまい、~/ros/fuerteで行うと今まで同じ表示となってしまいます。最後にまた、つけさせていただいてます。

~/.git/configは、
mechuser@UoT-IST-Ub:~/.git$ cat config
[core]
repositoryformatversion = 0
filemode = true
bare = false
logallrefupdates = true

となっております。

昨日から引き続きありがとうございます。
よろしくお願いします。

Merge caused no change, matching elements already exist
リビジョン 17263 です。
[multimaster_experimental] Done.
[turtlebot] Updating /home/mechuser/ros/fuerte/turtlebot
変更点を探索中
差分はありません
ファイル状態: 更新数 0、マージ数 0、削除数 0、衝突未解決数 0
[turtlebot] Done.
[webots-ros-pkg] Updating /home/mechuser/ros/fuerte/webots-ros-pkg
リビジョン 16 です。
[webots-ros-pkg] Done.
Exception caught during install: Error processing 'umd-ros-pkg/camera_umd' : [umd-ros-pkg/camera_umd] Checkout of http://ram.umd.edu/git/ros/camera_umd.git version master into /home/mechuser/ros/fuerte/umd-ros-pkg/camera_umd failed.

ERROR: Error processing 'umd-ros-pkg/camera_umd' : [umd-ros-pkg/camera_umd] Checkout of http://ram.umd.edu/git/ros/camera_umd.git version master into /home/mechuser/ros/fuerte/umd-ros-pkg/camera_umd failed.



2012年11月20日火曜日 3時45分27秒 UTC+9 垣内(JSK):

>> >> >> >>>> > このグループに投稿するには、rtm-ros-robo...@googlegroups.com
>> >> >> >>>> > にメールを送信してください。
>> >> >> >>>> > このグループから退会するには、rtm-ros-robotics+unsubscribe@googlegroups.com


>> >> >> >>>> > にメールを送信してください。
>> >> >> >>>> > 詳細については、http://groups.google.com/group/rtm-ros-robotics?hl=ja
>> >> >> >>>> > からこのグループにアクセスしてください。
>> >> >> >>>
>> >> >> >>> --
>> >> >> >>> このメールは Google グループのグループ「rtm-ros-robotics」の登録者に送られています。
>> >> >> >>>
>> >> >> >>>
>> >> >> >>>
>> >> >> >>>
>> >> >> >>> このディスカッションをウェブ上で閲覧するには、https://groups.google.com/d/msg/rtm-ros-robotics/-/96iaEyXPA24J
>> >> >> >>> にアクセスしてください。

>> >> >> >>> このグループに投稿するには、rtm-ros-robo...@googlegroups.com にメールを送信してください。
>> >> >> >>> このグループから退会するには、rtm-ros-robotics+unsubscribe@googlegroups.com


>> >> >> >>> にメールを送信してください。
>> >> >> >>> 詳細については、http://groups.google.com/group/rtm-ros-robotics?hl=ja
>> >> >> >>> からこのグループにアクセスしてください。
>> >> >> >
>> >> >> > --
>> >> >> > このメールは Google グループのグループ「rtm-ros-robotics」の登録者に送られています。
>> >> >> >
>> >> >> >
>> >> >> >
>> >> >> > このディスカッションをウェブ上で閲覧するには、https://groups.google.com/d/msg/rtm-ros-robotics/-/rj7mfpLznvAJ
>> >> >> > にアクセスしてください。
>> >> >> >

>> >> >> > このグループに投稿するには、rtm-ros-robo...@googlegroups.com にメールを送信してください。
>> >> >> > このグループから退会するには、rtm-ros-robotics+unsubscribe@googlegroups.com


>> >> >> > にメールを送信してください。
>> >> >> > 詳細については、http://groups.google.com/group/rtm-ros-robotics?hl=ja
>> >> >> > からこのグループにアクセスしてください。
>> >> >
>> >> > --
>> >> > このメールは Google グループのグループ「rtm-ros-robotics」の登録者に送られています。
>> >> >
>> >> >
>> >> > このディスカッションをウェブ上で閲覧するには、https://groups.google.com/d/msg/rtm-ros-robotics/-/PLHJC3epc34J
>> >> > にアクセスしてください。
>> >> >

>> >> > このグループに投稿するには、rtm-ros-robo...@googlegroups.com にメールを送信してください。
>> >> > このグループから退会するには、rtm-ros-robotics+unsubscribe@googlegroups.com


>> >> > にメールを送信してください。
>> >> > 詳細については、http://groups.google.com/group/rtm-ros-robotics?hl=ja
>> >> > からこのグループにアクセスしてください。
>> >
>> > --
>> > このメールは Google グループのグループ「rtm-ros-robotics」の登録者に送られています。
>> >
>> > このディスカッションをウェブ上で閲覧するには、https://groups.google.com/d/msg/rtm-ros-robotics/-/LHsPRKE7WzgJ
>> > にアクセスしてください。
>> >

>> > このグループに投稿するには、rtm-ros-robo...@googlegroups.com にメールを送信してください。
>> > このグループから退会するには、rtm-ros-robotics+unsubscribe@googlegroups.com


>> > にメールを送信してください。
>> > 詳細については、http://groups.google.com/group/rtm-ros-robotics?hl=ja
>> > からこのグループにアクセスしてください。
>
> --
> このメールは Google グループのグループ「rtm-ros-robotics」の登録者に送られています。
> このディスカッションをウェブ上で閲覧するには、https://groups.google.com/d/msg/rtm-ros-robotics/-/zDpkevrJc3cJ
> にアクセスしてください。
>

> このグループに投稿するには、rtm-ros-robo...@googlegroups.com にメールを送信してください。
> このグループから退会するには、rtm-ros-robotics+unsubscribe@googlegroups.com にメールを送信してください。
> 詳細については、http://groups.google.com/group/rtm-ros-robotics?hl=ja
> からこのグループにアクセスしてください。

Yohei Kakiuchi

unread,
Nov 19, 2012, 10:15:37 PM11/19/12
to rtm-ros-...@googlegroups.com
ls ~/ros/fuerte/camera_umd/.git は何がありますか?

また、set と打って出てくる文字列を送ってください。


2012年11月20日 9:42 yuto inagaki <yuto.i...@gmail.com>:

>> >> >> >> >>>> > このグループに投稿するには、rtm-ros-...@googlegroups.com
>> >> >> >> >>>> > にメールを送信してください。
>> >> >> >> >>>> >
>> >> >> >> >>>> > このグループから退会するには、rtm-ros-roboti...@googlegroups.com


>> >> >> >> >>>> > にメールを送信してください。
>> >> >> >> >>>> >
>> >> >> >> >>>> > 詳細については、http://groups.google.com/group/rtm-ros-robotics?hl=ja
>> >> >> >> >>>> > からこのグループにアクセスしてください。
>> >> >> >> >>>
>> >> >> >> >>> --
>> >> >> >> >>> このメールは Google グループのグループ「rtm-ros-robotics」の登録者に送られています。
>> >> >> >> >>>
>> >> >> >> >>>
>> >> >> >> >>>
>> >> >> >> >>>
>> >> >> >> >>>
>> >> >> >> >>> このディスカッションをウェブ上で閲覧するには、https://groups.google.com/d/msg/rtm-ros-robotics/-/96iaEyXPA24J
>> >> >> >> >>> にアクセスしてください。

>> >> >> >> >>> このグループに投稿するには、rtm-ros-...@googlegroups.com
>> >> >> >> >>> にメールを送信してください。
>> >> >> >> >>> このグループから退会するには、rtm-ros-roboti...@googlegroups.com


>> >> >> >> >>> にメールを送信してください。
>> >> >> >> >>> 詳細については、http://groups.google.com/group/rtm-ros-robotics?hl=ja
>> >> >> >> >>> からこのグループにアクセスしてください。
>> >> >> >> >
>> >> >> >> > --
>> >> >> >> > このメールは Google グループのグループ「rtm-ros-robotics」の登録者に送られています。
>> >> >> >> >
>> >> >> >> >
>> >> >> >> >
>> >> >> >> >
>> >> >> >> > このディスカッションをウェブ上で閲覧するには、https://groups.google.com/d/msg/rtm-ros-robotics/-/rj7mfpLznvAJ
>> >> >> >> > にアクセスしてください。
>> >> >> >> >

>> >> >> >> > このグループに投稿するには、rtm-ros-...@googlegroups.com にメールを送信してください。
>> >> >> >> > このグループから退会するには、rtm-ros-roboti...@googlegroups.com


>> >> >> >> > にメールを送信してください。
>> >> >> >> > 詳細については、http://groups.google.com/group/rtm-ros-robotics?hl=ja
>> >> >> >> > からこのグループにアクセスしてください。
>> >> >> >
>> >> >> > --
>> >> >> > このメールは Google グループのグループ「rtm-ros-robotics」の登録者に送られています。
>> >> >> >
>> >> >> >
>> >> >> >
>> >> >> > このディスカッションをウェブ上で閲覧するには、https://groups.google.com/d/msg/rtm-ros-robotics/-/PLHJC3epc34J
>> >> >> > にアクセスしてください。
>> >> >> >

>> >> >> > このグループに投稿するには、rtm-ros-...@googlegroups.com にメールを送信してください。
>> >> >> > このグループから退会するには、rtm-ros-roboti...@googlegroups.com


>> >> >> > にメールを送信してください。
>> >> >> > 詳細については、http://groups.google.com/group/rtm-ros-robotics?hl=ja
>> >> >> > からこのグループにアクセスしてください。
>> >> >
>> >> > --
>> >> > このメールは Google グループのグループ「rtm-ros-robotics」の登録者に送られています。
>> >> >
>> >> >
>> >> > このディスカッションをウェブ上で閲覧するには、https://groups.google.com/d/msg/rtm-ros-robotics/-/LHsPRKE7WzgJ
>> >> > にアクセスしてください。
>> >> >

>> >> > このグループに投稿するには、rtm-ros-...@googlegroups.com にメールを送信してください。
>> >> > このグループから退会するには、rtm-ros-roboti...@googlegroups.com


>> >> > にメールを送信してください。
>> >> > 詳細については、http://groups.google.com/group/rtm-ros-robotics?hl=ja
>> >> > からこのグループにアクセスしてください。
>> >
>> > --
>> > このメールは Google グループのグループ「rtm-ros-robotics」の登録者に送られています。
>> >
>> > このディスカッションをウェブ上で閲覧するには、https://groups.google.com/d/msg/rtm-ros-robotics/-/zDpkevrJc3cJ
>> > にアクセスしてください。
>> >

>> > このグループに投稿するには、rtm-ros-...@googlegroups.com にメールを送信してください。
>> > このグループから退会するには、rtm-ros-roboti...@googlegroups.com


>> > にメールを送信してください。
>> > 詳細については、http://groups.google.com/group/rtm-ros-robotics?hl=ja
>> > からこのグループにアクセスしてください。
>
> --
> このメールは Google グループのグループ「rtm-ros-robotics」の登録者に送られています。

> このディスカッションをウェブ上で閲覧するには、https://groups.google.com/d/msg/rtm-ros-robotics/-/ix0XVZ9irxQJ
> にアクセスしてください。
>
> このグループに投稿するには、rtm-ros-...@googlegroups.com にメールを送信してください。
> このグループから退会するには、rtm-ros-roboti...@googlegroups.com にメールを送信してください。
> 詳細については、http://groups.google.com/group/rtm-ros-robotics?hl=ja
> からこのグループにアクセスしてください。

yuto inagaki

unread,
Nov 20, 2012, 4:28:29 AM11/20/12
to rtm-ros-...@googlegroups.com
~/ros/fuerte以下には、camera_umdのフォルダはできませんでした。
そのフォルダは、~/直下には作れたのですが、

mechuser@UoT-IST-Ub:~$ ls ~/camera_umd/.git/
HEAD      config       hooks  info  objects      refs
branches  description  index  logs  packed-refs

となっております。



以下が、setのログです。

                                                                     
                                                                     
                                                                     
                                             
ARCHDIR=Linux
BASH=/bin/bash
BASHOPTS=checkwinsize:cmdhist:expand_aliases:extglob:extquote:force_fignore:histappend:interactive_comments:progcomp:promptvars:sourcepath
BASH_ALIASES=()
BASH_ARGC=()
BASH_ARGV=()
BASH_CMDS=()
BASH_COMPLETION=/etc/bash_completion
BASH_COMPLETION_COMPAT_DIR=/etc/bash_completion.d
BASH_COMPLETION_DIR=/etc/bash_completion.d
BASH_LINENO=()
BASH_SOURCE=()
BASH_VERSINFO=([0]="4" [1]="1" [2]="5" [3]="1" [4]="release" [5]="i486-pc-linux-gnu")
BASH_VERSION='4.1.5(1)-release'
CATKIN_SHELL=bash
CMAKE_PREFIX_PATH=/opt/ros/fuerte/share/catkin/cmake/Modules:/opt/ros/fuerte:/opt/ros/fuerte/share/catkin/cmake/Modules:/opt/ros/fuerte:
COLORTERM=gnome-terminal
COLUMNS=73
COMP_WORDBREAKS=$' \t\n"\'><=;|&(:'
CVSDIR=/home/mechuser/prog
CVS_RSH=ssh
DBUS_SESSION_BUS_ADDRESS=unix:abstract=/tmp/dbus-c4ZQuamGnT,guid=2beb160713a068b77b30e9b250ab1e0a
DEFAULTS_PATH=/usr/share/gconf/gnome.default.path
DESKTOP_SESSION=gnome
DIRSTACK=()
DISPLAY=:0.0
EUID=1001
EUSDIR=/home/mechuser/prog/jskeus/eus
FIND=/usr/bin/find
GDMSESSION=gnome
GDM_KEYBOARD_LAYOUT=$'jp\tOADG109A'
GDM_LANG=ja_JP.utf8
GNOME_DESKTOP_SESSION_ID=this-is-deprecated
GNOME_KEYRING_CONTROL=/tmp/keyring-Y7dn3k
GNOME_KEYRING_PID=2652
GROUPS=()
GTK_IM_MODULE=ibus
GTK_MODULES=canberra-gtk-module
HISTCONTROL=ignoreboth
HISTFILE=/home/mechuser/.bash_history
HISTFILESIZE=500
HISTSIZE=500
HOME=/home/mechuser
HOSTNAME=UoT-IST-Ub
HOSTTYPE=i486
IFS=$' \t\n'
JLESSCHARSET=japanese
LANG=ja_JP.UTF-8
LANGUAGE=ja_JP:ja:en_GB:en
LD_LIBRARY_PATH=/opt/ros/fuerte/lib:/opt/ros/fuerte/lib:/home/mechuser/prog/jskeus/eus/Linux/bin:.:/usr/lib:/lib:/usr/local/jsk/lib:/usr/local/lib
LESSCLOSE='/usr/bin/lesspipe %s %s'
LESSOPEN='| /usr/bin/lesspipe %s'
LINES=39
LOGNAME=mechuser
LS_COLORS='rs=0:di=01;34:ln=01;36:hl=44;37:pi=40;33:so=01;35:do=01;35:bd=40;33;01:cd=40;33;01:or=40;31;01:su=37;41:sg=30;43:ca=30;41:tw=30;42:ow=34;42:st=37;44:ex=01;32:*.tar=01;31:*.tgz=01;31:*.arj=01;31:*.taz=01;31:*.lzh=01;31:*.lzma=01;31:*.zip=01;31:*.z=01;31:*.Z=01;31:*.dz=01;31:*.gz=01;31:*.bz2=01;31:*.bz=01;31:*.tbz2=01;31:*.tz=01;31:*.deb=01;31:*.rpm=01;31:*.jar=01;31:*.rar=01;31:*.ace=01;31:*.zoo=01;31:*.cpio=01;31:*.7z=01;31:*.rz=01;31:*.jpg=01;35:*.jpeg=01;35:*.gif=01;35:*.bmp=01;35:*.pbm=01;35:*.pgm=01;35:*.ppm=01;35:*.tga=01;35:*.xbm=01;35:*.xpm=01;35:*.tif=01;35:*.tiff=01;35:*.png=01;35:*.svg=01;35:*.svgz=01;35:*.mng=01;35:*.pcx=01;35:*.mov=01;35:*.mpg=01;35:*.mpeg=01;35:*.m2v=01;35:*.mkv=01;35:*.ogm=01;35:*.mp4=01;35:*.m4v=01;35:*.mp4v=01;35:*.vob=01;35:*.qt=01;35:*.nuv=01;35:*.wmv=01;35:*.asf=01;35:*.rm=01;35:*.rmvb=01;35:*.flc=01;35:*.avi=01;35:*.fli=01;35:*.flv=01;35:*.gl=01;35:*.dl=01;35:*.xcf=01;35:*.xwd=01;35:*.yuv=01;35:*.axv=01;35:*.anx=01;35:*.ogv=01;35:*.ogx=01;35:*.aac=00;36:*.au=00;36:*.flac=00;36:*.mid=00;36:*.midi=00;36:*.mka=00;36:*.mp3=00;36:*.mpc=00;36:*.ogg=00;36:*.ra=00;36:*.wav=00;36:*.axa=00;36:*.oga=00;36:*.spx=00;36:*.xspf=00;36:'
MACHTYPE=i486-pc-linux-gnu
MAILCHECK=60
MANDATORY_PATH=/usr/share/gconf/gnome.mandatory.path
OLDPWD=/home/mechuser
OLDPWDBAK=
OPTERR=1
OPTIND=1
ORBIT_SOCKETDIR=/tmp/orbit-mechuser
OSTYPE=linux-gnu
PATH=/opt/ros/fuerte/share/ros/bin:/opt/ros/fuerte/bin:/opt/ros/fuerte/bin:/home/mechuser/prog/jskeus/eus/Linux/bin:.:/home/mechuser/bin:/usr/local/bin:/usr/java/j2sdk1.4.1/bin/:/usr/bin:/bin/:/usr/sbin:/sbin:/usr/X11R6/bin:/usr/local/jsk/bin:/home/mechuser/frandoll/:/usr/local/Trolltech/Qt-4.8.2/:/home/mechuser/ros/fuerte/jsk-ros-pkg/roseus/bin
PIPESTATUS=([0]="0")
PKG_CONFIG_PATH=/opt/ros/fuerte/lib/pkgconfig:/opt/ros/fuerte/lib/pkgconfig:
PPID=2903
PS1='\[\e]0;\u@\h: \w\a\]${debian_chroot:+($debian_chroot)}\u@\h:\w\$ '
PS2='> '
PS4='+ '
PWD=/home/mechuser/ros/fuerte
PYTHONPATH=/opt/ros/fuerte/share/ros/core/roslib/src:/opt/ros/fuerte/lib/python2.6/dist-packages:/opt/ros/fuerte/lib/python2.6/dist-packages:
QT_IM_MODULE=xim
RETURNCODE=
ROSLISP_PACKAGE_DIRECTORY=/opt/ros/fuerte/share/common-lisp/ros
ROS_DISTRO=fuerte
ROS_ETC_DIR=/opt/ros/fuerte/etc/ros
ROS_MASTER_URI=http://localhost:11311
ROS_PACKAGE_PATH=/home/mechuser/ros/fuerte/stacks/:/home/mechuser/ros/fuerte/webots-ros-pkg:/home/mechuser/ros/fuerte/turtlebot:/home/mechuser/ros/fuerte/multimaster_experimental:/home/mechuser/ros/fuerte/ccny-vision:/home/mechuser/ros/fuerte/ua-ros-pkg:/home/mechuser/ros/fuerte/tum-ros-pkg:/home/mechuser/ros/fuerte/wg-ros-pkg-cturtle/sandbox/checkerboard_pose:/home/mechuser/ros/fuerte/wg-ros-pkg-cturtle/vision:/home/mechuser/ros/fuerte/cmu-ros-pkg:/home/mechuser/ros/fuerte/ros-pkg-git/kinect:/home/mechuser/ros/fuerte/stacks/camera1394:/home/mechuser/ros/fuerte/umd-ros-pkg/camera_umd:/home/mechuser/ros/fuerte/rtm-ros-robotics/agentsystem_ros_tutorials:/home/mechuser/ros/fuerte/rtm-ros-robotics/rtmros_common:/opt/ros/electric/stacks:/opt/ros/electric/ros:/home/mechuser/ros/fuerte/jsk-ros-pkg:/opt/ros/fuerte/stacks:/opt/ros/fuerte/share:/opt/ros/fuerte/share/ros:/home/mechuser/ros/fuerte/jsk-ros-pkg/
ROS_ROOT=/opt/ros/fuerte/share/ros
ROS_WORKSPACE=/home/mechuser/ros/fuerte
SCRIPT_PATH=/home/mechuser/ros/fuerte
SESSION_MANAGER=local/UoT-IST-Ub:@/tmp/.ICE-unix/2670,unix/UoT-IST-Ub:/tmp/.ICE-unix/2670
SHELL=/bin/bash
SHELLOPTS=braceexpand:emacs:hashall:histexpand:history:interactive-comments:monitor
SHLVL=1
SPEECHD_PORT=7561
SSH_AGENT_PID=2706
SSH_AUTH_SOCK=/tmp/keyring-Y7dn3k/ssh
TERM=xterm
UID=1001
UNAME=/bin//uname
USER=mechuser
USERNAME=mechuser
WINDOWID=67108867
XAUTHORITY=/var/run/gdm/auth-for-mechuser-BbT9yi/database
XDG_CONFIG_DIRS=/etc/xdg/xdg-gnome:/etc/xdg
XDG_DATA_DIRS=/usr/share/gnome:/usr/local/share/:/usr/share/
XDG_SESSION_COOKIE=f96224d72553b999905965bb4b6aa260-1353391626.228724-6842883
XMODIFIERS=@im=ibus
_=set
__git_all_commands=
__git_diff_common_options=$'--stat --numstat --shortstat --summary\n\t\t\t--patch-with-stat --name-only --name-status --color\n\t\t\t--no-color --color-words --no-renames --check\n\t\t\t--full-index --binary --abbrev --diff-filter=\n\t\t\t--find-copies-harder\n\t\t\t--text --ignore-space-at-eol --ignore-space-change\n\t\t\t--ignore-all-space --exit-code --quiet --ext-diff\n\t\t\t--no-ext-diff\n\t\t\t--no-prefix --src-prefix= --dst-prefix=\n\t\t\t--inter-hunk-context=\n\t\t\t--patience\n\t\t\t--raw\n\t\t\t--dirstat --dirstat= --dirstat-by-file\n\t\t\t--dirstat-by-file= --cumulative\n'
__git_fetch_options=$'\n\t--quiet --verbose --append --upload-pack --force --keep --depth=\n\t--tags --no-tags --all --prune --dry-run\n'
__git_log_common_options=$'\n\t--not --all\n\t--branches --tags --remotes\n\t--first-parent --merges --no-merges\n\t--max-count=\n\t--max-age= --since= --after=\n\t--min-age= --until= --before=\n'
__git_log_date_formats='relative iso8601 rfc2822 short local default raw'
__git_log_gitk_options=$'\n\t--dense --sparse --full-history\n\t--simplify-merges --simplify-by-decoration\n\t--left-right\n'
__git_log_pretty_formats='oneline short medium full fuller email raw format:'
__git_log_shortlog_options=$'\n\t--author= --committer= --grep=\n\t--all-match\n'
__git_merge_options=$'\n\t--no-commit --no-stat --log --no-log --squash --strategy\n\t--commit --stat --no-squash --ff --no-ff --ff-only\n'
__git_merge_strategies=
__git_mergetools_common=$'diffuse ecmerge emerge kdiff3 meld opendiff\n\t\t\ttkdiff vimdiff gvimdiff xxdiff araxis p4merge\n'
__git_porcelain_commands=
__git_send_email_confirm_options='always never auto cc compose'
__git_send_email_suppresscc_options='author self cc bodycc sob cccmd body all'
__git_whitespacelist='nowarn warn error error-all fix'
__pkcon_commandlist=$'\n    accept-eula\n    get-actions\n    get-depends\n    get-details\n    get-distro-upgrades\n    get-files\n    get-filters\n    get-groups\n    get-packages\n    download\n    get-requires\n    get-time\n    get-transactions\n    get-update-detail\n    get-updates\n    get-categories\n    list-create\n    list-diff\n    list-install\n    install\n    install-local\n    refresh\n    remove\n    repo-disable\n    repo-enable\n    repo-list\n    repo-set-data\n    resolve\n    search\n    update\n    '
bash205='4.1.5(1)-release'
bash205b='4.1.5(1)-release'
bash3='4.1.5(1)-release'
bash4='4.1.5(1)-release'
envfile=/opt/ros/fuerte/etc/catkin/profile.d/00.catkin.bash
_ImageMagick () 
{ 
    local prev;
    prev=${COMP_WORDS[COMP_CWORD-1]};
    case "$prev" in 
        -channel)
            COMPREPLY=($( compgen -W 'Red Green Blue Opacity \
                Matte Cyan Magenta Yellow Black' -- "$cur" ));
            return 0
        ;;
        -colormap)
            COMPREPLY=($( compgen -W 'shared private' -- "$cur" ));
            return 0
        ;;
        -colorspace)
            COMPREPLY=($( compgen -W 'GRAY OHTA RGB Transparent \
                XYZ YCbCr YIQ YPbPr YUV CMYK' -- "$cur" ));
            return 0
        ;;
        -compose)
            COMPREPLY=($( compgen -W 'Over In Out Atop Xor Plus \
                Minus Add Subtract Difference Multiply Bumpmap\
                Copy CopyRed CopyGreen CopyBlue CopyOpacity' -- "$cur" ));
            return 0
        ;;
        -compress)
            COMPREPLY=($( compgen -W 'None BZip Fax Group4 JPEG \
                Lossless LZW RLE Zip' -- "$cur" ));
            return 0
        ;;
        -dispose)
            COMPREPLY=($( compgen -W 'Undefined None Background Previous'                 -- "$cur" ));
            return 0
        ;;
        -encoding)
            COMPREPLY=($( compgen -W 'AdobeCustom AdobeExpert \
                AdobeStandard AppleRoman BIG5 GB2312 Latin2 \
                None SJIScode Symbol Unicode Wansung' -- "$cur"));
            return 0
        ;;
        -endian)
            COMPREPLY=($( compgen -W 'MSB LSB' -- "$cur" ));
            return 0
        ;;
        -filter)
            COMPREPLY=($( compgen -W 'Point Box Triangle Hermite \
                Hanning Hamming Blackman Gaussian Quadratic \
                Cubic Catrom Mitchell Lanczos Bessel Sinc' -- "$cur" ));
            return 0
        ;;
        -format)
            COMPREPLY=($( compgen -W "$( convert -list format |                 awk '/ [r-][w-][+-] / {print $1}' |                 tr -d '*' | tr [:upper:] [:lower:] )" -- "$cur" ));
            return 0
        ;;
        -gravity)
            COMPREPLY=($( compgen -W 'Northwest North NorthEast \
                West Center East SouthWest South SouthEast' -- "$cur" ));
            return 0
        ;;
        -intent)
            COMPREPLY=($( compgen -W 'Absolute Perceptual \
                Relative Saturation' -- "$cur" ));
            return 0
        ;;
        -interlace)
            COMPREPLY=($( compgen -W 'None Line Plane Partition' -- "$cur" ));
            return 0
        ;;
        -limit)
            COMPREPLY=($( compgen -W 'Disk File Map Memory' -- "$cur" ));
            return 0
        ;;
        -list)
            COMPREPLY=($( compgen -W 'Delegate Format Magic Module Resource \
                Type' -- "$cur" ));
            return 0
        ;;
        -map)
            COMPREPLY=($( compgen -W 'best default gray red green blue'                 -- "$cur" ));
            _filedir;
            return 0
        ;;
        -noise)
            COMPREPLY=($( compgen -W 'Uniform Gaussian Multiplicative \
                Impulse Laplacian Poisson' -- "$cur" ));
            return 0
        ;;
        -preview)
            COMPREPLY=($( compgen -W 'Rotate Shear Roll Hue \
                Saturation Brightness Gamma Spiff \
                Dull Grayscale Quantize Despeckle \
                ReduceNoise AddNoise Sharpen Blur \
                Treshold EdgeDetect Spread Shade \
                Raise Segment Solarize Swirl Implode \
                Wave OilPaint CharcoalDrawing JPEG' -- "$cur" ));
            return 0
        ;;
        -@(mask|profile|texture|tile|write))
            _filedir;
            return 0
        ;;
        -type)
            COMPREPLY=($( compgen -W 'Bilevel Grayscale Palette PaletteMatte \
                TrueColor TrueColorMatte ColorSeparation ColorSeparationlMatte \
                Optimize' -- "$cur" ));
            return 0
        ;;
        -units)
            COMPREPLY=($( compgen -W 'Undefined PixelsPerInch \
                PixelsPerCentimeter' -- "$cur" ));
            return 0
        ;;
        -virtual-pixel)
            COMPREPLY=($( compgen -W 'Constant Edge mirror tile' -- "$cur" ));
            return 0
        ;;
        -visual)
            COMPREPLY=($( compgen -W 'StaticGray GrayScale StaticColor \
                PseudoColor TrueColor DirectColor defaut visualid' -- "$cur" ));
            return 0
        ;;
    esac
}
__get_cword3 () 
{ 
    if [[ "${#COMP_WORDS[COMP_CWORD]}" -eq 0 ]] || [[ "$COMP_POINT" == "${#COMP_LINE}" ]]; then
        printf "%s" "${COMP_WORDS[COMP_CWORD]}";
    else
        local i;
        local cur="$COMP_LINE";
        local index="$COMP_POINT";
        for ((i = 0; i <= COMP_CWORD; ++i ))
        do
            while [[ "${#cur}" -ge ${#COMP_WORDS[i]} && "${cur:0:${#COMP_WORDS[i]}}" != "${COMP_WORDS[i]}" ]]; do
                cur="${cur:1}";
                index="$(( index - 1 ))";
            done;
            if [[ "$i" -lt "$COMP_CWORD" ]]; then
                local old_size="${#cur}";
                cur="${cur#${COMP_WORDS[i]}}";
                local new_size="${#cur}";
                index="$(( index - old_size + new_size ))";
            fi;
        done;
        if [[ "${COMP_WORDS[COMP_CWORD]:0:${#cur}}" != "$cur" ]]; then
            printf "%s" "${COMP_WORDS[COMP_CWORD]}";
        else
            printf "%s" "${cur:0:$index}";
        fi;
    fi
}
__get_cword4 () 
{ 
    local i;
    local LC_CTYPE=C;
    local WORDBREAKS=$COMP_WORDBREAKS;
    WORDBREAKS=${WORDBREAKS//\"/};
    WORDBREAKS=${WORDBREAKS//\'/};
    if [ -n "$1" ]; then
        for ((i=0; i<${#1}; ++i ))
        do
            local char=${1:$i:1};
            WORDBREAKS=${WORDBREAKS//$char/};
        done;
    fi;
    local cur=${COMP_LINE:0:$COMP_POINT};
    local tmp=$cur;
    local word_start=`expr "$tmp" : '.*['"$WORDBREAKS"']'`;
    while [ "$word_start" -ge 2 ]; do
        local char=${cur:$(( $word_start - 2 )):1};
        if [ "$char" != "\\" ]; then
            break;
        fi;
        tmp=${COMP_LINE:0:$(( $word_start - 2 ))};
        word_start=`expr "$tmp" : '.*['"$WORDBREAKS"']'`;
    done;
    cur=${cur:$word_start};
    printf "%s" "$cur"
}
__git_aliased_command () 
{ 
    local word cmdline=$(git --git-dir="$(__gitdir)" 		config --get "alias.$1");
    for word in $cmdline;
    do
        if [ "${word##-*}" ]; then
            echo $word;
            return;
        fi;
    done
}
__git_aliases () 
{ 
    local i IFS='
';
    for i in $(git --git-dir="$(__gitdir)" config --get-regexp "alias\..*" 2>/dev/null);
    do
        case "$i" in 
            alias.*)
                i="${i#alias.}";
                echo "${i/ */}"
            ;;
        esac;
    done
}
__git_complete_file () 
{ 
    local pfx ls ref cur="${COMP_WORDS[COMP_CWORD]}";
    case "$cur" in 
        ?*:*)
            ref="${cur%%:*}";
            cur="${cur#*:}";
            case "$cur" in 
                ?*/*)
                    pfx="${cur%/*}";
                    cur="${cur##*/}";
                    ls="$ref:$pfx";
                    pfx="$pfx/"
                ;;
                *)
                    ls="$ref"
                ;;
            esac;
            case "$COMP_WORDBREAKS" in 
                *:*)
                    : great
                ;;
                *)
                    pfx="$ref:$pfx"
                ;;
            esac;
            local IFS='
';
            COMPREPLY=($(compgen -P "$pfx" 			-W "$(git --git-dir="$(__gitdir)" ls-tree "$ls" 				| sed '/^100... blob /{
				           s,^.*	,,
				           s,$, ,
				       }
				       /^120000 blob /{
				           s,^.*	,,
				           s,$, ,
				       }
				       /^040000 tree /{
				           s,^.*	,,
				           s,$,/,
				       }
				       s/^.*	//')" 			-- "$cur"))
        ;;
        *)
            __gitcomp "$(__git_refs)"
        ;;
    esac
}
__git_complete_remote_or_refspec () 
{ 
    local cmd="${COMP_WORDS[1]}";
    local cur="${COMP_WORDS[COMP_CWORD]}";
    local i c=2 remote="" pfx="" lhs=1 no_complete_refspec=0;
    while [ $c -lt $COMP_CWORD ]; do
        i="${COMP_WORDS[c]}";
        case "$i" in 
            --mirror)
                [ "$cmd" = "push" ] && no_complete_refspec=1
            ;;
            --all)
                case "$cmd" in 
                    push)
                        no_complete_refspec=1
                    ;;
                    fetch)
                        COMPREPLY=();
                        return
                    ;;
                    *)

                    ;;
                esac
            ;;
            -*)

            ;;
            *)
                remote="$i";
                break
            ;;
        esac;
        c=$((++c));
    done;
    if [ -z "$remote" ]; then
        __gitcomp "$(__git_remotes)";
        return;
    fi;
    if [ $no_complete_refspec = 1 ]; then
        COMPREPLY=();
        return;
    fi;
    [ "$remote" = "." ] && remote=;
    case "$cur" in 
        *:*)
            case "$COMP_WORDBREAKS" in 
                *:*)
                    : great
                ;;
                *)
                    pfx="${cur%%:*}:"
                ;;
            esac;
            cur="${cur#*:}";
            lhs=0
        ;;
        +*)
            pfx="+";
            cur="${cur#+}"
        ;;
    esac;
    case "$cmd" in 
        fetch)
            if [ $lhs = 1 ]; then
                __gitcomp "$(__git_refs2 "$remote")" "$pfx" "$cur";
            else
                __gitcomp "$(__git_refs)" "$pfx" "$cur";
            fi
        ;;
        pull)
            if [ $lhs = 1 ]; then
                __gitcomp "$(__git_refs "$remote")" "$pfx" "$cur";
            else
                __gitcomp "$(__git_refs)" "$pfx" "$cur";
            fi
        ;;
        push)
            if [ $lhs = 1 ]; then
                __gitcomp "$(__git_refs)" "$pfx" "$cur";
            else
                __gitcomp "$(__git_refs "$remote")" "$pfx" "$cur";
            fi
        ;;
    esac
}
__git_complete_revlist () 
{ 
    local pfx cur="${COMP_WORDS[COMP_CWORD]}";
    case "$cur" in 
        *...*)
            pfx="${cur%...*}...";
            cur="${cur#*...}";
            __gitcomp "$(__git_refs)" "$pfx" "$cur"
        ;;
        *..*)
            pfx="${cur%..*}..";
            cur="${cur#*..}";
            __gitcomp "$(__git_refs)" "$pfx" "$cur"
        ;;
        *)
            __gitcomp "$(__git_refs)"
        ;;
    esac
}
__git_complete_strategy () 
{ 
    __git_compute_merge_strategies;
    case "${COMP_WORDS[COMP_CWORD-1]}" in 
        -s | --strategy)
            __gitcomp "$__git_merge_strategies";
            return 0
        ;;
    esac;
    local cur="${COMP_WORDS[COMP_CWORD]}";
    case "$cur" in 
        --strategy=*)
            __gitcomp "$__git_merge_strategies" "" "${cur##--strategy=}";
            return 0
        ;;
    esac;
    return 1
}
__git_compute_all_commands () 
{ 
    : ${__git_all_commands:=$(__git_list_all_commands)}
}
__git_compute_merge_strategies () 
{ 
    : ${__git_merge_strategies:=$(__git_list_merge_strategies)}
}
__git_compute_porcelain_commands () 
{ 
    __git_compute_all_commands;
    : ${__git_porcelain_commands:=$(__git_list_porcelain_commands)}
}
__git_config_get_set_variables () 
{ 
    local prevword word config_file= c=$COMP_CWORD;
    while [ $c -gt 1 ]; do
        word="${COMP_WORDS[c]}";
        case "$word" in 
            --global | --system | --file=*)
                config_file="$word";
                break
            ;;
            -f | --file)
                config_file="$word $prevword";
                break
            ;;
        esac;
        prevword=$word;
        c=$((--c));
    done;
    git --git-dir="$(__gitdir)" config $config_file --list 2> /dev/null | while read line; do
        case "$line" in 
            *.*=*)
                echo "${line/=*/}"
            ;;
        esac;
    done
}
__git_find_on_cmdline () 
{ 
    local word subcommand c=1;
    while [ $c -lt $COMP_CWORD ]; do
        word="${COMP_WORDS[c]}";
        for subcommand in $1;
        do
            if [ "$subcommand" = "$word" ]; then
                echo "$subcommand";
                return;
            fi;
        done;
        c=$((++c));
    done
}
__git_has_doubledash () 
{ 
    local c=1;
    while [ $c -lt $COMP_CWORD ]; do
        if [ "--" = "${COMP_WORDS[c]}" ]; then
            return 0;
        fi;
        c=$((++c));
    done;
    return 1
}
__git_heads () 
{ 
    local cmd i is_hash=y dir="$(__gitdir "${1-}")";
    if [ -d "$dir" ]; then
        git --git-dir="$dir" for-each-ref --format='%(refname:short)' refs/heads;
        return;
    fi;
    for i in $(git ls-remote "${1-}" 2>/dev/null);
    do
        case "$is_hash,$i" in 
            y,*)
                is_hash=n
            ;;
            n,*^{})
                is_hash=y
            ;;
            n,refs/heads/*)
                is_hash=y;
                echo "${i#refs/heads/}"
            ;;
            n,*)
                is_hash=y;
                echo "$i"
            ;;
        esac;
    done
}
__git_list_all_commands () 
{ 
    local i IFS=" "'
';
    for i in $(git help -a|egrep '^  [a-zA-Z0-9]');
    do
        case $i in 
            *--*)
                : helper pattern
            ;;
            *)
                echo $i
            ;;
        esac;
    done
}
__git_list_merge_strategies () 
{ 
    git merge -s help 2>&1 | sed -n -e '/[Aa]vailable strategies are: /,/^$/{
		s/\.$//
		s/.*://
		s/^[ 	]*//
		s/[ 	]*$//
		p
	}'
}
__git_list_porcelain_commands () 
{ 
    local i IFS=" "'
';
    __git_compute_all_commands;
    for i in "help" $__git_all_commands;
    do
        case $i in 
            *--*)
                : helper pattern
            ;;
            applymbox)
                : ask gittus
            ;;
            applypatch)
                : ask gittus
            ;;
            archimport)
                : import
            ;;
            cat-file)
                : plumbing
            ;;
            check-attr)
                : plumbing
            ;;
            check-ref-format)
                : plumbing
            ;;
            checkout-index)
                : plumbing
            ;;
            commit-tree)
                : plumbing
            ;;
            count-objects)
                : infrequent
            ;;
            cvsexportcommit)
                : export
            ;;
            cvsimport)
                : import
            ;;
            cvsserver)
                : daemon
            ;;
            daemon)
                : daemon
            ;;
            diff-files)
                : plumbing
            ;;
            diff-index)
                : plumbing
            ;;
            diff-tree)
                : plumbing
            ;;
            fast-import)
                : import
            ;;
            fast-export)
                : export
            ;;
            fsck-objects)
                : plumbing
            ;;
            fetch-pack)
                : plumbing
            ;;
            fmt-merge-msg)
                : plumbing
            ;;
            for-each-ref)
                : plumbing
            ;;
            hash-object)
                : plumbing
            ;;
            http-*)
                : transport
            ;;
            index-pack)
                : plumbing
            ;;
            init-db)
                : deprecated
            ;;
            local-fetch)
                : plumbing
            ;;
            lost-found)
                : infrequent
            ;;
            ls-files)
                : plumbing
            ;;
            ls-remote)
                : plumbing
            ;;
            ls-tree)
                : plumbing
            ;;
            mailinfo)
                : plumbing
            ;;
            mailsplit)
                : plumbing
            ;;
            merge-*)
                : plumbing
            ;;
            mktree)
                : plumbing
            ;;
            mktag)
                : plumbing
            ;;
            pack-objects)
                : plumbing
            ;;
            pack-redundant)
                : plumbing
            ;;
            pack-refs)
                : plumbing
            ;;
            parse-remote)
                : plumbing
            ;;
            patch-id)
                : plumbing
            ;;
            peek-remote)
                : plumbing
            ;;
            prune)
                : plumbing
            ;;
            prune-packed)
                : plumbing
            ;;
            quiltimport)
                : import
            ;;
            read-tree)
                : plumbing
            ;;
            receive-pack)
                : plumbing
            ;;
            reflog)
                : plumbing
            ;;
            remote-*)
                : transport
            ;;
            repo-config)
                : deprecated
            ;;
            rerere)
                : plumbing
            ;;
            rev-list)
                : plumbing
            ;;
            rev-parse)
                : plumbing
            ;;
            runstatus)
                : plumbing
            ;;
            sh-setup)
                : internal
            ;;
            shell)
                : daemon
            ;;
            show-ref)
                : plumbing
            ;;
            send-pack)
                : plumbing
            ;;
            show-index)
                : plumbing
            ;;
            ssh-*)
                : transport
            ;;
            stripspace)
                : plumbing
            ;;
            symbolic-ref)
                : plumbing
            ;;
            tar-tree)
                : deprecated
            ;;
            unpack-file)
                : plumbing
            ;;
            unpack-objects)
                : plumbing
            ;;
            update-index)
                : plumbing
            ;;
            update-ref)
                : plumbing
            ;;
            update-server-info)
                : daemon
            ;;
            upload-archive)
                : plumbing
            ;;
            upload-pack)
                : plumbing
            ;;
            write-tree)
                : plumbing
            ;;
            var)
                : infrequent
            ;;
            verify-pack)
                : infrequent
            ;;
            verify-tag)
                : plumbing
            ;;
            *)
                echo $i
            ;;
        esac;
    done
}
__git_ps1 () 
{ 
    local g="$(__gitdir)";
    if [ -n "$g" ]; then
        local r;
        local b;
        if [ -f "$g/rebase-merge/interactive" ]; then
            r="|REBASE-i";
            b="$(cat "$g/rebase-merge/head-name")";
        else
            if [ -d "$g/rebase-merge" ]; then
                r="|REBASE-m";
                b="$(cat "$g/rebase-merge/head-name")";
            else
                if [ -d "$g/rebase-apply" ]; then
                    if [ -f "$g/rebase-apply/rebasing" ]; then
                        r="|REBASE";
                    else
                        if [ -f "$g/rebase-apply/applying" ]; then
                            r="|AM";
                        else
                            r="|AM/REBASE";
                        fi;
                    fi;
                else
                    if [ -f "$g/MERGE_HEAD" ]; then
                        r="|MERGING";
                    else
                        if [ -f "$g/BISECT_LOG" ]; then
                            r="|BISECTING";
                        fi;
                    fi;
                fi;
                b="$(git symbolic-ref HEAD 2>/dev/null)" || { 
                    b="$(
				case "${GIT_PS1_DESCRIBE_STYLE-}" in
				(contains)
					git describe --contains HEAD ;;
				(branch)
					git describe --contains --all HEAD ;;
				(describe)
					git describe HEAD ;;
				(* | default)
					git describe --exact-match HEAD ;;
				esac 2>/dev/null)" || b="$(cut -c1-7 "$g/HEAD" 2>/dev/null)..." || b="unknown";
                    b="($b)"
                };
            fi;
        fi;
        local w;
        local i;
        local s;
        local u;
        local c;
        if [ "true" = "$(git rev-parse --is-inside-git-dir 2>/dev/null)" ]; then
            if [ "true" = "$(git rev-parse --is-bare-repository 2>/dev/null)" ]; then
                c="BARE:";
            else
                b="GIT_DIR!";
            fi;
        else
            if [ "true" = "$(git rev-parse --is-inside-work-tree 2>/dev/null)" ]; then
                if [ -n "${GIT_PS1_SHOWDIRTYSTATE-}" ]; then
                    if [ "$(git config --bool bash.showDirtyState)" != "false" ]; then
                        git diff --no-ext-diff --quiet --exit-code || w="*";
                        if git rev-parse --quiet --verify HEAD > /dev/null; then
                            git diff-index --cached --quiet HEAD -- || i="+";
                        else
                            i="#";
                        fi;
                    fi;
                fi;
                if [ -n "${GIT_PS1_SHOWSTASHSTATE-}" ]; then
                    git rev-parse --verify refs/stash > /dev/null 2>&1 && s="$";
                fi;
                if [ -n "${GIT_PS1_SHOWUNTRACKEDFILES-}" ]; then
                    if [ -n "$(git ls-files --others --exclude-standard)" ]; then
                        u="%";
                    fi;
                fi;
            fi;
        fi;
        local f="$w$i$s$u";
        printf "${1:- (%s)}" "$c${b##refs/heads/}${f:+ $f}$r";
    fi
}
__git_refs () 
{ 
    local i is_hash=y dir="$(__gitdir "${1-}")";
    local cur="${COMP_WORDS[COMP_CWORD]}" format refs;
    if [ -d "$dir" ]; then
        case "$cur" in 
            refs | refs/*)
                format="refname";
                refs="${cur%/*}"
            ;;
            *)
                for i in HEAD FETCH_HEAD ORIG_HEAD MERGE_HEAD;
                do
                    if [ -e "$dir/$i" ]; then
                        echo $i;
                    fi;
                done;
                format="refname:short";
                refs="refs/tags refs/heads refs/remotes"
            ;;
        esac;
        git --git-dir="$dir" for-each-ref --format="%($format)" $refs;
        return;
    fi;
    for i in $(git ls-remote "$dir" 2>/dev/null);
    do
        case "$is_hash,$i" in 
            y,*)
                is_hash=n
            ;;
            n,*^{})
                is_hash=y
            ;;
            n,refs/tags/*)
                is_hash=y;
                echo "${i#refs/tags/}"
            ;;
            n,refs/heads/*)
                is_hash=y;
                echo "${i#refs/heads/}"
            ;;
            n,refs/remotes/*)
                is_hash=y;
                echo "${i#refs/remotes/}"
            ;;
            n,*)
                is_hash=y;
                echo "$i"
            ;;
        esac;
    done
}
__git_refs2 () 
{ 
    local i;
    for i in $(__git_refs "$1");
    do
        echo "$i:$i";
    done
}
__git_refs_remotes () 
{ 
    local cmd i is_hash=y;
    for i in $(git ls-remote "$1" 2>/dev/null);
    do
        case "$is_hash,$i" in 
            n,refs/heads/*)
                is_hash=y;
                echo "$i:refs/remotes/$1/${i#refs/heads/}"
            ;;
            y,*)
                is_hash=n
            ;;
            n,*^{})
                is_hash=y
            ;;
            n,refs/tags/*)
                is_hash=y
            ;;
            n,*)
                is_hash=y
            ;;
        esac;
    done
}
__git_remotes () 
{ 
    local i ngoff IFS='
' d="$(__gitdir)";
    shopt -q nullglob || ngoff=1;
    shopt -s nullglob;
    for i in "$d/remotes"/*;
    do
        echo ${i#$d/remotes/};
    done;
    [ "$ngoff" ] && shopt -u nullglob;
    for i in $(git --git-dir="$d" config --get-regexp 'remote\..*\.url' 2>/dev/null);
    do
        i="${i#remote.}";
        echo "${i/.url*/}";
    done
}
__git_tags () 
{ 
    local cmd i is_hash=y dir="$(__gitdir "${1-}")";
    if [ -d "$dir" ]; then
        git --git-dir="$dir" for-each-ref --format='%(refname:short)' refs/tags;
        return;
    fi;
    for i in $(git ls-remote "${1-}" 2>/dev/null);
    do
        case "$is_hash,$i" in 
            y,*)
                is_hash=n
            ;;
            n,*^{})
                is_hash=y
            ;;
            n,refs/tags/*)
                is_hash=y;
                echo "${i#refs/tags/}"
            ;;
            n,*)
                is_hash=y;
                echo "$i"
            ;;
        esac;
    done
}
__gitcomp () 
{ 
    local cur="${COMP_WORDS[COMP_CWORD]}";
    if [ $# -gt 2 ]; then
        cur="$3";
    fi;
    case "$cur" in 
        --*=)
            COMPREPLY=()
        ;;
        *)
            local IFS='
';
            COMPREPLY=($(compgen -P "${2-}" 			-W "$(__gitcomp_1 "${1-}" "${4-}")" 			-- "$cur"))
        ;;
    esac
}
__gitcomp_1 () 
{ 
    local c IFS=' ''	''
';
    for c in $1;
    do
        case "$c$2" in 
            --*=*)
                printf %s'
' "$c$2"
            ;;
            *.)
                printf %s'
' "$c$2"
            ;;
            *)
                printf %s'
' "$c$2 "
            ;;
        esac;
    done
}
__gitdir () 
{ 
    if [ -z "${1-}" ]; then
        if [ -n "${__git_dir-}" ]; then
            echo "$__git_dir";
        else
            if [ -d .git ]; then
                echo .git;
            else
                git rev-parse --git-dir 2> /dev/null;
            fi;
        fi;
    else
        if [ -d "$1/.git" ]; then
            echo "$1/.git";
        else
            echo "$1";
        fi;
    fi
}
__gvfs_multiple_uris () 
{ 
    local IFS='
';
    local cur="${COMP_WORDS[COMP_CWORD]}";
    COMPREPLY=($(compgen -W '$(gvfs-ls --show-completions "$cur")' -- ""));
    case "$cur" in 
        *:*)
            case "$COMP_WORDBREAKS" in 
                *:*)
                    colon_prefix=$(echo $cur | sed 's/:[^:]*$/:/' );
                    COMPREPLY=${COMPREPLY##${colon_prefix}}
                ;;
            esac
        ;;
    esac
}
__pkconcomp () 
{ 
    local all c s='
' IFS=' ''	''
';
    local cur="${COMP_WORDS[COMP_CWORD]}";
    if [ $# -gt 2 ]; then
        cur="$3";
    fi;
    for c in $1;
    do
        case "$c$4" in 
            *.)
                all="$all$c$4$s"
            ;;
            *)
                all="$all$c$4 $s"
            ;;
        esac;
    done;
    IFS=$s;
    COMPREPLY=($(compgen -P "$2" -W "$all" -- "$cur"));
    return
}
_a2dismod () 
{ 
    local cur;
    COMPREPLY=();
    cur=${COMP_WORDS[COMP_CWORD]};
    _apache2_modsites mods-enabled
}
_a2dissite () 
{ 
    local cur;
    COMPREPLY=();
    cur=${COMP_WORDS[COMP_CWORD]};
    _apache2_modsites sites-enabled
}
_a2enmod () 
{ 
    local cur;
    COMPREPLY=();
    cur=${COMP_WORDS[COMP_CWORD]};
    _apache2_modsites mods-available
}
_a2ensite () 
{ 
    local cur;
    COMPREPLY=();
    cur=${COMP_WORDS[COMP_CWORD]};
    _apache2_modsites sites-available
}
_acroread () 
{ 
    local cur prev opts files;
    COMPREPLY=();
    cur="${COMP_WORDS[COMP_CWORD]}";
    first="${COMP_WORDS[1]}";
    opts="--display --screen --sync -geometry -help -man -iconic -setenv -tempFile -tempFileTitle -toPostScript -openInNewWindow -installCertificate -v -version";
    case "${first}" in 
        -toPostScript)
            if [[ "${cur}" == -* ]]; then
                local running="-binary -start -end -pairs -optimizeForSpeed -landscape -reverse -odd -even -commentsOff -annotsOff -stampsOff -markupsOn -level2 -level3 -printerhalftones -saveVM -size -shrink  -expand -transQuality -printerName -nUp -booklet -rotateAndCenter -choosePaperByPDFPageSize";
                COMPREPLY=($(compgen -W "${running}" -- "${cur}"));
                return 0;
            fi
        ;;
        -installCertificate)
            if [[ "${cur}" == -* ]]; then
                if [ $COMP_CWORD -eq 2 ]; then
                    local running="-PEM -DER";
                    COMPREPLY=($(compgen -W "${running}" -- "${cur}"));
                    return 0;
                fi;
            fi
        ;;
        *)

        ;;
    esac;
    if [[ "${cur}" == -* ]]; then
        COMPREPLY=($(compgen -W "${opts}" -- "${cur}"));
        return 0;
    fi;
    if [ $COMP_CWORD -eq 1 -o "${COMPREPLY+set}" != "set" ]; then
        _filedir '[pP][dD][fF]';
    fi
}
_alias () 
{ 
    local cur;
    COMPREPLY=();
    cur=`_get_cword`;
    case "$COMP_LINE" in 
        *[^=])
            COMPREPLY=($( compgen -A alias -- "$cur" ))
        ;;
        *=)
            COMPREPLY=("$( alias ${cur%=} 2>/dev/null | sed                 -e 's|^alias '"$cur"'\(.*\)$|\1|' )")
        ;;
    esac
}
_animate () 
{ 
    local cur;
    COMPREPLY=();
    cur=`_get_cword`;
    _ImageMagick;
    if [[ "$cur" == -* ]]; then
        COMPREPLY=($( compgen -W '-alpha -authenticate -backdrop \
            -background -bordercolor -borderwidth -channel \
            -coalesce -colormap -colors -colorspace -crop -debug \
            -decipher -define -delay -density -depth -display \
            -dispose -dither -extract -filter -flatten -font \
            -foreground -format -gamma -geometry -help \
            -iconGeometry -iconic -identify -immutable -interlace \
            -interpolate -limit -list -log -loop -map -mattecolor \
            -mattecolor -monitor -monochrome -name -page -pause \
            -quantize -quiet -regard-warnings -remote -repage \
            -resample -resize -respect-parenthesis -rotate \
            -sampling-factor -scenes -seed -set -shared-memory \
            -size -strip -title -transparent-color -treedepth \
            -trim -verbose -version -virtual-pixel -visual \
            -window' -- "$cur" ));
    else
        if [[ "$cur" == +* ]]; then
            COMPREPLY=($( compgen -W '+debug +dither +gamma +map +matte'             -- "$cur" ));
        else
            _filedir;
        fi;
    fi
}
_apache2_modsites () 
{ 
    COMPREPLY=($( compgen -W '$( command ls /etc/apache2/$1 2>/dev/null \
               | sed -e 's/\.load//' -e 's/\.conf//' )' -- $cur  ))
}
_apache2ctl () 
{ 
    local APWORDS;
    COMPREPLY=();
    cur=`_get_cword`;
    APWORDS=$(apache2ctl 2>&1 >/dev/null | head -n1 | cut -f3 -d" " |         tr "|" " ");
    COMPREPLY=($( compgen -W "$APWORDS" -- "$cur" ))
}
_apport-bug () 
{ 
    local cur dashoptions prev param;
    COMPREPLY=();
    cur=`_get_cword`;
    prev=${COMP_WORDS[COMP_CWORD-1]};
    dashoptions='-h --help -f --file-bug -u --update-bug -s --symptom -p \
                 --package -P --pid -c --crash-file --save -v --version';
    case "$prev" in 
        ubuntu-bug | apport-bug)
            case "$cur" in 
                -*)
                    COMPREPLY=($( compgen -W "$dashoptions" -- $cur ))
                ;;
                *)
                    _apport_parameterless
                ;;
            esac
        ;;
        -f | --file-bug)
            param="-P --pid -p --package -s --symptom";
            COMPREPLY=($( compgen -W "$param $(_apport_symptoms)" -- $cur))
        ;;
        -p | --package)
            COMPREPLY=($( apt-cache pkgnames $cur 2> /dev/null ))
        ;;
        -u | --update-bug)
            param="-p --package";
            COMPREPLY=($( compgen -W "$param" -- $cur))
        ;;
        -s | --symptom)
            COMPREPLY=($( compgen -W "$(_apport_symptoms)" -- $cur))
        ;;
        -P | --pid)
            COMPREPLY=($( compgen -W '$( command ps axo pid | sed 1d )' -- $cur ))
        ;;
        --save)
            COMPREPLY=($( compgen -o default -G "$cur*" ))
        ;;
        -c | --crash-file)
            COMPREPLY=($( compgen -G "${cur}*.apport"
                       compgen -G "${cur}*.crash" ))
        ;;
        -h | --help | -v | --version)
            return 0
        ;;
        *)
            if [ "${COMP_WORDS[COMP_CWORD-2]}" == "--save" ]; then
                case "$cur" in 
                    -*)
                        COMPREPLY=($( compgen -W "$dashoptions" -- $cur ))
                    ;;
                    *)
                        _apport_parameterless
                    ;;
                esac;
            else
                param="--save";
                COMPREPLY=($( compgen -W "$param" -- $cur));
            fi
        ;;
    esac
}
_apport-cli () 
{ 
    local cur dashoptions prev param;
    COMPREPLY=();
    cur=`_get_cword`;
    prev=${COMP_WORDS[COMP_CWORD-1]};
    dashoptions='-h --help -f --file-bug -u --update-bug -s --symptom \
                 -c --crash-file --save -v --version';
    case "$prev" in 
        apport-cli)
            case "$cur" in 
                -*)
                    COMPREPLY=($( compgen -W "$dashoptions" -- $cur ))
                ;;
                *)
                    _apport_parameterless
                ;;
            esac
        ;;
        -f | --file-bug)
            param="-P --pid -p --package -s --symptom";
            COMPREPLY=($( compgen -W "$param $(_apport_symptoms)" -- $cur))
        ;;
        -s | --symptom)
            COMPREPLY=($( compgen -W "$(_apport_symptoms)" -- $cur))
        ;;
        --save)
            COMPREPLY=($( compgen -o default -G "$cur*" ))
        ;;
        -c | --crash-file)
            COMPREPLY=($( compgen -G "${cur}*.apport"
                       compgen -G "${cur}*.crash" ))
        ;;
        -h | --help | -v | --version)
            return 0
        ;;
        *)
            if [ "${COMP_WORDS[COMP_CWORD-2]}" == "--save" ]; then
                case "$cur" in 
                    -*)
                        COMPREPLY=($( compgen -W "$dashoptions" -- $cur ))
                    ;;
                    *)
                        _apport_parameterless
                    ;;
                esac;
            else
                param="--save";
                COMPREPLY=($( compgen -W "$param" -- $cur));
            fi
        ;;
    esac
}
_apport-collect () 
{ 
    local cur prev;
    COMPREPLY=();
    cur=`_get_cword`;
    prev=${COMP_WORDS[COMP_CWORD-1]};
    case "$prev" in 
        apport-collect)
            COMPREPLY=($( compgen -W "-p --package" -- $cur))
        ;;
        -p | --package)
            COMPREPLY=($( apt-cache pkgnames $cur 2> /dev/null ))
        ;;
    esac
}
_apport-unpack () 
{ 
    local cur prev;
    COMPREPLY=();
    cur=`_get_cword`;
    prev=${COMP_WORDS[COMP_CWORD-1]};
    case "$prev" in 
        apport-unpack)
            COMPREPLY=($( compgen -G "${cur}*.apport"
                       compgen -G "${cur}*.crash" ))
        ;;
    esac
}
_apport_parameterless () 
{ 
    local param;
    param="$dashoptions            $( apt-cache pkgnames $cur 2> /dev/null )            $( command ps axo pid | sed 1d )            $( _apport_symptoms )            $( compgen -G "${cur}*.apport"
              compgen -G "${cur}*.crash" )";
    COMPREPLY=($( compgen -W "$param" -- $cur))
}
_apport_symptoms () 
{ 
    local syms;
    for FILE in $(ls /usr/share/apport/symptoms);
    do
        syms="$syms ${FILE%.py}";
    done;
    echo $syms
}
_apt_cache () 
{ 
    local cur prev special i;
    COMPREPLY=();
    cur=`_get_cword`;
    prev=${COMP_WORDS[COMP_CWORD-1]};
    if [ "$cur" != show ]; then
        for ((i=0; i < ${#COMP_WORDS[@]}-1; i++ ))
        do
            if [[ ${COMP_WORDS[i]} == @(add|depends|dotty|madison|policy|rdepends|show?(pkg|src|)) ]]; then
                special=${COMP_WORDS[i]};
            fi;
        done;
    fi;
    if [ -n "$special" ]; then
        case $special in 
            add)
                _filedir;
                return 0
            ;;
            showsrc)
                COMPREPLY=($( apt-cache dumpavail |                             grep "^Source: $cur" | sort |                             uniq | cut -f2 -d" " ));
                return 0
            ;;
            *)
                COMPREPLY=($( apt-cache --no-generate pkgnames "$cur" 2> /dev/null ));
                return 0
            ;;
        esac;
    fi;
    case "$prev" in 
        -@(c|p|s|-config-file|-@(pkg|src)-cache))
            _filedir;
            return 0
        ;;
        search)
            if [[ "$cur" != -* ]]; then
                return 0;
            fi
        ;;
    esac;
    if [[ "$cur" == -* ]]; then
        COMPREPLY=($( compgen -W '-h -v -p -s -q -i -f -a -g -c \
                -o --help --version --pkg-cache --src-cache \
                --quiet --important --full --all-versions \
                --no-all-versions --generate --no-generate \
                --names-only --all-names --recurse \
                --config-file --option --installed' -- "$cur" ));
    else
        COMPREPLY=($( compgen -W 'add gencaches show showpkg showsrc \
                stats dump dumpavail unmet search search \
                depends rdepends pkgnames dotty xvcg \
                policy madison' -- "$cur" ));
    fi;
    return 0
}
_apt_get () 
{ 
    local cur prev special i;
    COMPREPLY=();
    cur=`_get_cword`;
    prev=${COMP_WORDS[COMP_CWORD-1]};
    for ((i=0; i < ${#COMP_WORDS[@]}-1; i++ ))
    do
        if [[ ${COMP_WORDS[i]} == @(install|remove|autoremove|purge|source|build-dep) ]]; then
            special=${COMP_WORDS[i]};
        fi;
    done;
    if [ -n "$special" ]; then
        case $special in 
            remove | autoremove | purge)
                if [ -f /etc/debian_version ]; then
                    COMPREPLY=($( _comp_dpkg_installed_packages $cur ));
                else
                    _rpm_installed_packages;
                fi;
                return 0
            ;;
            *)
                COMPREPLY=($( apt-cache --no-generate pkgnames "$cur"                     2> /dev/null ));
                return 0
            ;;
        esac;
    fi;
    case "$prev" in 
        -@(c|-config-file))
            _filedir;
            return 0
        ;;
        -@(t|-target-release|-default-release))
            COMPREPLY=($( apt-cache policy |                  grep "release.o=Debian,a=$cur" |                  sed -e "s/.*a=\(\w*\).*/\1/" | uniq 2> /dev/null));
            return 0
        ;;
    esac;
    if [[ "$cur" == -* ]]; then
        COMPREPLY=($( compgen -W '-d -f -h -v -m -q -s -y -u -t -b -c -o \
            --download-only --fix-broken --help --version --ignore-missing \
            --fix-missing --no-download --quiet --simulate --just-print \
            --dry-run --recon --no-act --yes --assume-yes --show-upgraded \
            --only-source --compile --build --ignore-hold --target-release \
            --no-upgrade --force-yes --print-uris --purge --reinstall \
            --list-cleanup --default-release --trivial-only --no-remove \
            --diff-only --no-install-recommends --tar-only --config-file \
            --option --auto-remove' -- "$cur" ));
    else
        COMPREPLY=($( compgen -W 'update upgrade dselect-upgrade \
            dist-upgrade install remove purge source build-dep \
            check clean autoclean autoremove' -- "$cur" ));
    fi;
    return 0
}
_aptitude () 
{ 
    local cur dashoptions prev special i;
    COMPREPLY=();
    cur=`_get_cword`;
    prev=${COMP_WORDS[COMP_CWORD-1]};
    dashoptions='-S -u -i -h --help --version -s --simulate -d \
        --download-only -P --prompt -y --assume-yes -F \
        --display-format -O --sort -w --width -f -r -g \
        --with-recommends -R -G --without-recommends -t \
        --target-release -V --show-versions -D --show-deps\
        -Z -v --verbose --purge-unused --schedule-only';
    for ((i=0; i < ${#COMP_WORDS[@]}-1; i++ ))
    do
        if [[ ${COMP_WORDS[i]} == @(install|reinstall|hold|unhold|markauto|unmarkauto|dist-upgrade|full-upgrade|download|show|forbid-version|purge|remove|changelog|why|why-not|keep|keep-all|build-dep) ]]; then
            special=${COMP_WORDS[i]};
        fi;
        [[ ${COMP_WORDS[i]} == '-u' ]] && dashoptions=${dashoptions/-i};
        [[ ${COMP_WORDS[i]} == '-i' ]] && dashoptions=${dashoptions/-u};
    done;
    if [[ -n "$special" ]]; then
        case $special in 
            @(install|hold|markauto|unmarkauto|dist-upgrade|full-upgrade|download|show|changelog|why|why-not|build-dep))
                COMPREPLY=($( apt-cache pkgnames $cur 2> /dev/null ));
                return 0
            ;;
            @(purge|remove|reinstall|forbid-version))
                COMPREPLY=($( _comp_dpkg_installed_packages "$cur" ));
                return 0
            ;;
            unhold)
                COMPREPLY=($( _comp_dpkg_hold_packages "$cur" ));
                return 0
            ;;
        esac;
    fi;
    case $prev in 
        @(autoclean|clean|forget-new|search|upgrade|safe-upgrade|update|keep-all))
            return 0
        ;;
        -S)
            _filedir;
            return 0
        ;;
        -@(t|-target-release|-default-release))
            COMPREPLY=($( apt-cache policy |                 grep "release.o=Debian,a=$cur" |                 sed -e "s/.*a=\(\w*\).*/\1/" | uniq 2> /dev/null ));
            return 0
        ;;
    esac;
    if [[ "$cur" == -* ]]; then
        COMPREPLY=($( compgen -W "$dashoptions" -- "$cur" ));
    else
        COMPREPLY=($( compgen -W 'update upgrade safe-upgrade forget-new \
            clean autoclean install reinstall remove \
            hold unhold purge markauto unmarkauto why why-not \
            dist-upgrade full-upgrade download search show \
            forbid-version changelog keep-all build-dep' -- "$cur" ));
    fi;
    return 0
}
_arch () 
{ 
    local cur prev split=false;
    COMPREPLY=();
    cur=`_get_cword`;
    prev=${COMP_WORDS[COMP_CWORD-1]};
    _split_longopt && split=true;
    case "$prev" in 
        -@(w|g|d|--welcome-msg|-goodbye-msg|-digest))
            COMPREPLY=($( compgen -W 'y n' -- "$cur"));
            return 0
        ;;
        -@(d|-file))
            _filedir;
            return 0
        ;;
    esac;
    $split && return 0;
    if [[ "$cur" == -* ]]; then
        COMPREPLY=($( compgen -W '--wipe -s --start -e --end -q --quiet -h \
            --help' -- "$cur" ));
    else
        args=$COMP_CWORD;
        for ((i=1; i < COMP_CWORD; i++ ))
        do
            if [[ "${COMP_WORDS[i]}" == -* ]]; then
                args=$(($args-1));
            fi;
        done;
        case $args in 
            1)
                _mailman_lists
            ;;
            2)
                _filedir
            ;;
        esac;
    fi
}
_aspell () 
{ 
    local cur prev split=false;
    COMPREPLY=();
    cur=`_get_cword`;
    prev=${COMP_WORDS[COMP_CWORD-1]};
    _split_longopt && split=true;
    case "$prev" in 
        -c | -p | check | --@(conf|personal|repl|per-conf))
            _filedir;
            return 0
        ;;
        --@(conf-dir|data-dir|dict-dir|home-dir|local-data-dir|prefix))
            _filedir -d;
            return 0
        ;;
        dump | create | merge)
            COMPREPLY=($( compgen -W 'master personal repl' -- "$cur" ));
            return 0
        ;;
        --mode)
            COMPREPLY=($( compgen -W 'none url email sgml tex' -- "$cur" ));
            return 0
        ;;
        --sug-mode)
            COMPREPLY=($( compgen -W 'ultra fast normal bad-speller' -- "$cur" ));
            return 0
        ;;
        --keymapping)
            COMPREPLY=($( compgen -W 'aspell ispell' -- "$cur" ));
            return 0
        ;;
        -d | --master)
            _aspell_dictionary;
            return 0
        ;;
    esac;
    $split && return 0;
    if [[ "$cur" == -* ]]; then
        COMPREPLY=($( compgen -W '--conf --conf-dir --data-dir --dict-dir \
            --encoding --add-filter --rem-filter --mode -e \
            -H -t --add-extra-dicts --rem-extra-dicts \
            --home-dir -W --ignore --ignore-accents \
            --dont-ignore-accents --ignore-case --dont-ignore-case \
            --ignore-repl --dont-ignore-repl --jargon --keyboard \
            --lang --language-tag --local-data-dir -d --master \
            --module --add-module-search-order \
            --rem-module-search-order --per-conf -p --personal \
            --prefix --repl -C -B --run-together --dont-run-together \
            --run-together-limit --run-together-min --save-repl \
            --dont-save-repl --set-prefix --dont-set-prefix --size \
            --spelling --strip-accents --dont-strip-accents \
            --sug-mode --add-word-list-path --rem-word-list-path \
            -b -x --backup -b|-x --dont-backup --reverse --dont-reverse \
            --time --dont-time --keymapping --add-email-quote \
            --rem-email-quote --email-margin --add-tex-command \
            --rem-tex-command --tex-check-comments \
            --dont-tex-check-comments --add-tex-extension \
            --rem-tex-extension --add-sgml-check --rem-sgml-check \
            --add-sgml-extension --rem-sgml-extension' -- "$cur" ));
    else
        COMPREPLY=($( compgen -W '-? help -c check -a pipe -l list \
            config config soundslike filter -v version dump \
            create merge' -- "$cur" ));
    fi
}
_aspell_dictionary () 
{ 
    local datadir;
    datadir=$( aspell config data-dir 2>/dev/null || echo /usr/lib/aspell );
    COMPREPLY=($( command ls $datadir/*.alias 2>/dev/null ));
    COMPREPLY=(${COMPREPLY[@]%.alias});
    COMPREPLY=(${COMPREPLY[@]#$datadir/});
    COMPREPLY=("${COMPREPLY[@]}" $( aspell dicts 2>/dev/null ));
    COMPREPLY=($( compgen -W '${COMPREPLY[@]}' -- "$cur" ))
}
_available_interfaces () 
{ 
    local cmd;
    if [ "${1:-}" = -w ]; then
        cmd="iwconfig";
    else
        if [ "${1:-}" = -a ]; then
            cmd="ifconfig";
        else
            cmd="ifconfig -a";
        fi;
    fi;
    COMPREPLY=($( eval $cmd 2>/dev/null |         awk '/^[^[:space:]]/ { print $1 }' ));
    COMPREPLY=($( compgen -W '${COMPREPLY[@]/%[[:punct:]]/}' -- "$cur" ))
}
_avctrl () 
{ 
    local cur;
    COMPREPLY=();
    cur=`_get_cword`;
    if [[ "$cur" == -* ]]; then
        COMPREPLY=($( compgen -W '-h --help -q --quiet' -- "$cur" ));
    else
        _count_args;
        if [ $args -eq 1 ]; then
            COMPREPLY=($( compgen -W 'discover switch' -- "$cur" ));
        fi;
    fi
}
_bluetooth_adresses () 
{ 
    if [ -n "${COMP_BLUETOOTH_SCAN:-}" ]; then
        COMPREPLY=(${COMPREPLY[@]:-} $( compgen -W "$( hcitool scan |             awk '/^\t/{print $1}' )" -- "$cur" ));
    fi
}
_bluetooth_devices () 
{ 
    COMPREPLY=(${COMPREPLY[@]:-} $( compgen -W "$( hcitool dev |         awk '/^\t/{print $1}' )" -- "$cur" ))
}
_bluetooth_packet_types () 
{ 
    COMPREPLY=($( compgen -W 'DM1 DM3 DM5 DH1 DH3 DH5 HV1 HV2 HV3'         -- "$cur" ))
}
_bluetooth_services () 
{ 
    COMPREPLY=($( compgen -W 'DID SP DUN LAN FAX OPUSH FTP HS HF HFAG \
        SAP NAP GN PANU HCRP HID CIP A2SRC A2SNK AVRCT AVRTG UDIUE \
        UDITE SYNCML' -- "$cur" ))
}
_bzip2 () 
{ 
    local cur prev xspec;
    COMPREPLY=();
    cur=`_get_cword`;
    prev=${COMP_WORDS[COMP_CWORD-1]};
    if [[ "$cur" == -* ]]; then
        COMPREPLY=($( compgen -W '-c -d -f -h -k -L -q -s \
            -t -v -V -z -1 -2 -3 -4 -5 -6 -7 -8 -9 \
            --help --decompress --compress --keep --force \
            --test --stdout --quiet --verbose --license \
            --version --small --fast --best' -- "$cur" ));
        return 0;
    fi;
    local IFS='	
';
    xspec="*.bz2";
    if [[ "$prev" == --* ]]; then
        [[ "$prev" == --decompress || "$prev" == --list || "$prev" == --test ]] && xspec="!"$xspec;
        [[ "$prev" == --compress ]] && xspec=;
    else
        if [[ "$prev" == -* ]]; then
            [[ "$prev" == -*[dt]* ]] && xspec="!"$xspec;
            [[ "$prev" == -*z* ]] && xspec=;
        fi;
    fi;
    _expand || return 0;
    COMPREPLY=($( compgen -f -X "$xspec" -- "$cur" ) $( compgen -d -- "$cur" ))
}
_bzr () 
{ 
    cur=${COMP_WORDS[COMP_CWORD]};
    prev=${COMP_WORDS[COMP_CWORD-1]};
    if [ $COMP_CWORD -eq 1 ]; then
        COMPREPLY=($( compgen -W "$(_bzr_commands)" -- "$cur" ));
    else
        if [ $COMP_CWORD -eq 2 ]; then
            case "$prev" in 
                help)
                    COMPREPLY=($( compgen -W "$(_bzr_commands) commands" -- "$cur" ))
                ;;
            esac;
        fi;
    fi
}
_bzr_commands () 
{ 
    bzr help commands | sed -r 's/^([-[:alnum:]]*).*/\1/' | grep --color=auto '^[[:alnum:]]'
}
_cancel () 
{ 
    local cur;
    COMPREPLY=();
    cur=`_get_cword`;
    COMPREPLY=($( compgen -W "$( lpstat | cut -d' ' -f1 )" -- "$cur" ))
}
_cd () 
{ 
    local IFS='	
' cur=`_get_cword` i j k;
    if [[ "$cur" == ?(\\)\$* ]]; then
        COMPREPLY=($( compgen -v -P '$' -- "${cur#?(\\)$}" ));
        return 0;
    fi;
    compgen -f /non-existing-dir/ > /dev/null;
    if [ -z "${CDPATH:-}" ] || [[ "$cur" == ?(.)?(.)/* ]]; then
        _filedir -d;
        return 0;
    fi;
    local -r mark_dirs=$(_rl_enabled mark-directories && echo y);
    local -r mark_symdirs=$(_rl_enabled mark-symlinked-directories && echo y);
    for i in ${CDPATH//:/'	'};
    do
        k="${#COMPREPLY[@]}";
        for j in $( compgen -d $i/$cur );
        do
            if [[ ( -n $mark_symdirs && -h $j || -n $mark_dirs && ! -h $j ) && ! -d ${j#$i/} ]]; then
                j="${j}/";
            fi;
            COMPREPLY[k++]=${j#$i/};
        done;
    done;
    _filedir -d;
    if [[ ${#COMPREPLY[@]} -eq 1 ]]; then
        i=${COMPREPLY[0]};
        if [ "$i" == "$cur" ] && [[ $i != "*/" ]]; then
            COMPREPLY[0]="${i}/";
        fi;
    fi;
    return 0
}
_cdrecord () 
{ 
    local cur prev i generic_options track_options track_mode;
    COMPREPLY=();
    cur=`_get_cword`;
    prev=${COMP_WORDS[COMP_CWORD-1]};
    if [[ "$cur" == *=* ]]; then
        prev=${cur/=*/};
        cur=${cur/*=/};
        case "$prev" in 
            @(text|cue)file)
                _filedir;
                return 0
            ;;
            blank)
                COMPREPLY=($( compgen -W 'help all fast \
                    track unreserve trtail unclose session'                     -- "$cur" ));
                return 0
            ;;
            driveropts)
                COMPREPLY=($( compgen -W 'burnfree noburnfree\
                    varirec= audiomaster forcespeed noforcespeed\
                    speedread nospeedread singlesession \
                    nosinglesession hidecdr nohidecdr tattooinfo\
                    tattoofile=' -- "$cur" ));
                return 0
            ;;
        esac;
    fi;
    generic_options=(-version -v -V -d -silent -s -force -immed -dummy -dao -raw -raw96r -raw96p -raw16 -multi -msinfo -toc -atip -fix -nofix -waiti -load -lock -eject -format -setdropts -checkdrive -prcap -inq -scanbus -reset -abort -overburn -ignsize -useinfo -packet -noclose -text debug= kdebug= kd= minbuf= speed= blank= fs= dev= gracetime= timeout= driver= driveropts= defpregap= pktsize= mcn= textfile= cuefile=);
    track_options=(-audio -swab -data -mode2 -xa -xa1 -xa2 -xamix -cdi -isosize -pad padsize= -nopad -shorttrack -noshorttrack pregap= -preemp -nopreemp -copy -nocopy -scms tcsize= isrc= index=);
    track_mode=0;
    if [ $COMP_CWORD -gt 1 ]; then
        if [ -f "$prev" ]; then
            track_mode=1;
        else
            for ((i=0; i < ${#track_options[@]}; i++ ))
            do
                if [[ "${track_options[i]}" == "$prev" ]]; then
                    track_mode=1;
                    break;
                fi;
            done;
        fi;
    fi;
    _filedir;
    COMPREPLY=("${COMPREPLY[@]}" $( compgen -W '${track_options[@]}' -- "$cur" ));
    if [ $track_mode -eq 0 ]; then
        COMPREPLY=("${COMPREPLY[@]}" $( compgen -W '${generic_options[@]}' -- "$cur" ));
    fi
}
_chage () 
{ 
    local cur prev split=false;
    COMPREPLY=();
    cur=`_get_cword`;
    prev=${COMP_WORDS[COMP_CWORD-1]};
    _split_longopt && split=true;
    case "$prev" in 
        -d | --lastday | -E | --expiredate | -h | --help | -I | --inactive | -m | --mindays | -M | --maxdays | -W | --warndays)
            return 0
        ;;
    esac;
    $split && return 0;
    if [[ "$cur" == -* ]]; then
        COMPREPLY=($( compgen -W '-d --lastday -E --expiredate \
            -h --help -I --inactive -l --list -m --mindays \
            -M --maxdays -W --warndays' -- "$cur" ));
        return 0;
    fi;
    COMPREPLY=($( compgen -u -- "$cur" ))
}
_chgrp () 
{ 
    local cur prev split=false;
    COMPREPLY=();
    cur=`_get_cword`;
    cur=${cur//\\\\/};
    prev=${COMP_WORDS[COMP_CWORD-1]};
    _split_longopt && split=true;
    if [[ "$prev" == --reference ]]; then
        _filedir;
        return 0;
    fi;
    $split && return 0;
    if [[ "$cur" == -* ]]; then
        COMPREPLY=($( compgen -W '-c -h -f -R -v --changes \
            --dereference --no-dereference --silent --quiet \
            --reference --recursive --verbose --help --version' -- "$cur" ));
        return 0;
    fi;
    if [ $COMP_CWORD -eq 1 ] && [[ "$cur" != -* ]] || [[ "$prev" == -* ]] && [ -n "$bash205" ]; then
        local IFS='
';
        COMPREPLY=($( compgen -g "$cur" 2>/dev/null ));
    else
        _filedir || return 0;
    fi;
    return 0
}
_chown () 
{ 
    local cur prev split=false;
    cur=`_get_cword`;
    prev=${COMP_WORDS[COMP_CWORD-1]};
    _split_longopt && split=true;
    case "$prev" in 
        --from)
            _usergroup;
            return 0
        ;;
        --reference)
            _filedir;
            return 0
        ;;
    esac;
    $split && return 0;
    if [[ "$cur" == -* ]]; then
        COMPREPLY=($( compgen -W '-c -h -f -R -v --changes \
            --dereference --no-dereference --from --silent --quiet \
            --reference --recursive --verbose --help --version' -- "$cur" ));
    else
        _count_args;
        case $args in 
            1)
                _usergroup
            ;;
            *)
                _filedir
            ;;
        esac;
    fi
}
_chpasswd () 
{ 
    local cur prev split=false;
    COMPREPLY=();
    cur=`_get_cword`;
    prev=${COMP_WORDS[COMP_CWORD-1]};
    _split_longopt && split=true;
    case "$prev" in 
        -c | --crypt)
            COMPREPLY=($( compgen -W 'DES MD5 NONE SHA256 SHA512'                 -- "$cur" ));
            return 0
        ;;
        -s | --sha-rounds)
            return 0
        ;;
    esac;
    $split && return 0;
    if [[ "$cur" == -* ]]; then
        COMPREPLY=($( compgen -W '-c --crypt-method -e --encrypted \
            -h --help -m --md5 -s --sha-rounds' -- "$cur" ));
        return 0;
    fi
}
_chsh () 
{ 
    local cur prev;
    COMPREPLY=();
    cur=`_get_cword`;
    prev=${COMP_WORDS[COMP_CWORD-1]};
    if [ "$prev" = "-s" ]; then
        _shells;
    else
        COMPREPLY=($( compgen -u -- "$cur" ));
    fi;
    return 0
}
_ciptool () 
{ 
    local cur prev;
    COMPREPLY=();
    cur=`_get_cword`;
    prev=${COMP_WORDS[COMP_CWORD-1]};
    case $prev in 
        -i)
            _bluetooth_devices;
            _bluetooth_adresses;
            return 0
        ;;
    esac;
    _get_command;
    if [ -z $command ]; then
        if [[ "$cur" == -* ]]; then
            COMPREPLY=($( compgen -W '-h --help -i' -- "$cur" ));
        else
            COMPREPLY=($( compgen -W 'show search connect release \
                loopback' -- "$cur" ));
        fi;
    else
        case $command in 
            @(connect|release|loopback))
                _count_args;
                if [ $args -eq 2 ]; then
                    _bluetooth_adresses;
                fi
            ;;
        esac;
    fi
}
_clisp () 
{ 
    local cur;
    COMPREPLY=();
    cur=`_get_cword`;
    if [[ "$cur" == -* ]]; then
        COMPREPLY=($( compgen -W '-h --help --version --license -B -K \
        -M -m -L -N -E -q --quiet --silent -w -I -ansi \
         -traditional -p -C -norc -i -c -l -o -x ' -- "$cur" ));
    else
        _filedir;
    fi;
    return 0
}
_command () 
{ 
    local offset i;
    offset=1;
    for ((i=1; i <= COMP_CWORD; i++ ))
    do
        if [[ "${COMP_WORDS[i]}" != -* ]]; then
            offset=$i;
            break;
        fi;
    done;
    _command_offset $offset
}
_command_offset () 
{ 
    local cur func cline cspec noglob cmd i char_offset word_offset _COMMAND_FUNC _COMMAND_FUNC_ARGS;
    word_offset=$1;
    local first_word=${COMP_WORDS[$word_offset]};
    for ((i=0; i <= ${#COMP_LINE}; i++ ))
    do
        if [[ "${COMP_LINE:$i:${#first_word}}" == "$first_word" ]]; then
            char_offset=$i;
            break;
        fi;
    done;
    COMP_LINE=${COMP_LINE:$char_offset};
    COMP_POINT=$(( COMP_POINT - $char_offset ));
    for ((i=0; i <= COMP_CWORD - $word_offset; i++ ))
    do
        COMP_WORDS[i]=${COMP_WORDS[i+$word_offset]};
    done;
    for ((i; i <= COMP_CWORD; i++ ))
    do
        unset COMP_WORDS[i];
    done;
    COMP_CWORD=$(( $COMP_CWORD - $word_offset ));
    COMPREPLY=();
    cur=`_get_cword`;
    if [[ $COMP_CWORD -eq 0 ]]; then
        COMPREPLY=($( compgen -c -- "$cur" ));
    else
        cmd=${COMP_WORDS[0]};
        if complete -p $cmd &>/dev/null; then
            cspec=$( complete -p $cmd );
            if [ "${cspec#* -F }" != "$cspec" ]; then
                func=${cspec#*-F };
                func=${func%% *};
                if [[ ${#COMP_WORDS[@]} -ge 2 ]]; then
                    $func $cmd "${COMP_WORDS[${#COMP_WORDS[@]}-1]}" "${COMP_WORDS[${#COMP_WORDS[@]}-2]}";
                else
                    $func $cmd "${COMP_WORDS[${#COMP_WORDS[@]}-1]}";
                fi;
                if [ "${cspec#*-o }" != "$cspec" ]; then
                    cspec=${cspec#*-o };
                    cspec=${cspec%% *};
                    if [[ "$cspec" != @(dir|file)names ]]; then
                        COMPREPLY=("${COMPREPLY[@]//\\\\:/:}");
                    fi;
                fi;
            else
                if [ -n "$cspec" ]; then
                    cspec=${cspec#complete};
                    cspec=${cspec%%$cmd};
                    COMPREPLY=($( eval compgen "$cspec" -- "$cur" ));
                fi;
            fi;
        fi;
    fi;
    [ ${#COMPREPLY[@]} -eq 0 ] && _filedir
}
_comp_dpkg_hold_packages () 
{ 
    grep --color=auto -B 2 'hold' /var/lib/dpkg/status | grep --color=auto "Package: $1" | cut -d\  -f2
}
_comp_dpkg_installed_packages () 
{ 
    grep --color=auto -A 1 "Package: $1" /var/lib/dpkg/status | grep --color=auto -B 1 -Ee "ok installed|half-installed|unpacked|             half-configured|config-files" -Ee "^Essential: yes" | grep --color=auto "Package: $1" | cut -d\  -f2
}
_compare () 
{ 
    local cur;
    COMPREPLY=();
    cur=`_get_cword`;
    _ImageMagick;
    if [[ "$cur" == -* ]]; then
        COMPREPLY=($( compgen -W '-alpha -authenticate -channel \
            -colorspace -compress -debug -decipher -define \
            -density -depth -encipher -extract -format -fuzz \
            -help -highlight-color -identify -interlace -limit \
            -list -log -metric -monitor -passphrase -profile \
            -quality -quantize -quiet -regard-warnings \
            -respect-parenthesis -sampling-factor -seed -set \
            -size -transparent-color -type -verbose -version \
            -virtual-pixel' -- "$cur" ));
    else
        if [[ "$cur" == +* ]]; then
            COMPREPLY=($( compgen -W '+debug' -- "$cur" ));
        else
            _filedir;
        fi;
    fi
}
_complete () 
{ 
    local cur prev options;
    COMPREPLY=();
    cur=`_get_cword`;
    prev=${COMP_WORDS[COMP_CWORD-1]};
    case $prev in 
        -o)
            options="default dirnames filenames";
            [ -n "$bash205b" ] && options="$options nospace";
            [ -n "$bash3" ] && options="$options bashdefault plusdirs";
            COMPREPLY=($( compgen -W "$options" -- "$cur" ));
            return 0
        ;;
        -A)
            COMPREPLY=($( compgen -W 'alias arrayvar binding \
                builtin command directory disabled enabled \
                export file function group helptopic hostname \
                job keyword running service setopt shopt \
                signal stopped user variable' -- "$cur" ));
            return 0
        ;;
        -C)
            COMPREPLY=($( compgen -A command -- "$cur" ));
            return 0
        ;;
        -F)
            COMPREPLY=($( compgen -A function -- "$cur" ));
            return 0
        ;;
        -@(p|r))
            COMPREPLY=($( complete -p | sed -e 's|.* ||' ));
            COMPREPLY=($( compgen -W '${COMPREPLY[@]}' -- "$cur" ));
            return 0
        ;;
    esac;
    if [[ "$cur" == -* ]]; then
        options="-a -b -c -d -e -f -g -j -k -s -v -u -A -G -W -P -S -X -F -C";
        [ -n "$bash205" ] && options="$options -o";
        COMPREPLY=($( compgen -W "$options" -- "$cur" ));
    else
        COMPREPLY=($( compgen -A command -- "$cur" ));
    fi
}
_composite () 
{ 
    local cur;
    COMPREPLY=();
    cur=`_get_cword`;
    _ImageMagick;
    if [[ "$cur" == -* ]]; then
        COMPREPLY=($( compgen -W '-affine -alpha -authenticate \
            -blend -blue-primary -border -bordercolor -channel \
            -colors -colorspace -comment -compose -compress \
            -debug -decipher -define -density -depth -displace \
            -display -dispose -dissolve -dither -encipher \
            -encoding -endian -extract -filter -font -format \
            -geometry -gravity -green-primary -help -identify \
            -interlace -interpolate -label -limit -list -log \
            -monitor -monochrome -negate -page -profile -quality \
            -quantize -quiet -red-primary -regard-warnings \
            -repage -resize -respect-parenthesis -rotate \
            -sampling-factor -scene -seed -sharpen -shave -size \
            -stegano -stereo -strip -swap -thumbnail -tile \
            -transform -transparent-color -treedepth -type -units \
            -unsharp -verbose -version -virtual-pixel -watermark \
            -white-point -write' -- "$cur" ));
    else
        if [[ "$cur" == +* ]]; then
            COMPREPLY=($( compgen -W '+compress +debug +dither +endian +label \
            +matte +negate +page +write' -- "$cur" ));
        else
            _filedir;
        fi;
    fi
}
_configure () 
{ 
    local cur;
    COMPREPLY=();
    cur=`_get_cword`;
    [[ "$cur" != -* ]] && return 0;
    if [ -n "$COMP_CONFIGURE_HINTS" ]; then
        COMPREPLY=($( compgen -W "$( $1 --help 2>&1 |             awk '/^  --[A-Za-z]/ { print $1; \
            if ($2 ~ /--[A-Za-z]/) print $2 }' | sed -e 's/[[,].*//g' )"             -- "$cur" ));
    else
        COMPREPLY=($( compgen -W "$( $1 --help 2>&1 |             awk '/^  --[A-Za-z]/ { print $1; \
            if ($2 ~ /--[A-Za-z]/) print $2 }' | sed -e 's/[[,=].*//g' )"             -- "$cur" ));
    fi
}
_configured_interfaces () 
{ 
    if [ -f /etc/debian_version ]; then
        COMPREPLY=($( compgen -W "$( sed -ne 's|^iface \([^ ]\+\).*$|\1|p'             /etc/network/interfaces )" -- "$cur" ));
    else
        if [ -f /etc/SuSE-release ]; then
            COMPREPLY=($( compgen -W "$( command ls             /etc/sysconfig/network/ifcfg-* |             sed -ne 's|.*ifcfg-\(.*\)|\1|p' )" -- "$cur" ));
        else
            if [ -f /etc/pld-release ]; then
                COMPREPLY=($( compgen -W "$( command ls -B             /etc/sysconfig/interfaces |             sed -ne 's|.*ifcfg-\(.*\)|\1|p' )" -- "$cur" ));
            else
                COMPREPLY=($( compgen -W "$( command ls             /etc/sysconfig/network-scripts/ifcfg-* |             sed -ne 's|.*ifcfg-\(.*\)|\1|p' )" -- "$cur" ));
            fi;
        fi;
    fi
}
_conjure () 
{ 
    local cur;
    COMPREPLY=();
    cur=`_get_cword`;
    _ImageMagick;
    if [[ "$cur" == -* ]]; then
        COMPREPLY=($( compgen -W '-debug -help -list -log -monitor -quiet \
            -regard-warnings -seed -verbose -version' -- "$cur" ));
    else
        if [[ "$cur" == +* ]]; then
            COMPREPLY=($( compgen -W '+debug' -- "$cur" ));
        else
            _filedir;
        fi;
    fi
}
_convert () 
{ 
    local cur;
    COMPREPLY=();
    cur=`_get_cword`;
    _ImageMagick;
    if [[ "$cur" == -* ]]; then
        COMPREPLY=($( compgen -W '-adaptive-blur -adaptive-resize \
            -adaptive-sharpen -adjoin -affine -alpha -annotate \
            -antialias -append -attenuate -authenticate \
            -auto-orient -average -background -bench -bias \
            -black-point-compensation -black-threshold \
            -blue-primary -blur -border -bordercolor -caption \
            -channel -charcoal -chop -clip -clip-mask -clip-path \
            -clone -clut -coalesce -colorize -colors -colorspace \
            -combine -comment -compose -composite -compress \
            -contrast -contrast-stretch -convolve -crop -cycle \
            -debug -decipher -deconstruct -define -delay -delete \
            -density -depth -despeckle -display -dispose -distort \
            -dither -draw -edge -emboss -encipher -encoding \
            -endian -enhance -equalize -evaluate -extent -extract \
            -family -fill -filter -flatten -flip -floodfill -flop \
            -font -format -frame -fuzz -fx -gamma -gaussian-blur \
            -geometry -gravity -green-primary -help -identify \
            -implode -insert -intent -interlace -interpolate \
            -label -lat -layers -level -limit -linear-stretch \
            -liquid-rescale -list -log -loop -map -mask \
            -mattecolor -median -modulate -monitor -monochrome \
            -morph -mosaic -motion-blur -negate -noise -normalize \
            -opaque -ordered-dither -orient -page -paint -ping \
            -pointsize -polaroid -posterize -preview -print \
            -process -profile -quality -quantize -quiet \
            -radial-blur -raise -random-threshold -recolor \
            -red-primary -regard-warnings -region -render -repage \
            -resample -resize -respect-parenthesis -reverse -roll \
            -rotate -sample -sampling-factor -scale -scene -seed \
            -segment -separate -sepia-tone -set -shade -shadow \
            -sharpen -shave -shear -sigmoidal-contrast -size \
            -sketch -solarize -splice -spread -stretch -strip \
            -stroke -strokewidth -style -swap -swirl -taint \
            -texture -threshold -thumbnail -tile -tile-offset \
            -tint -transform -transparent -transparent-color \
            -transpose -transverse -treedepth -trim -type \
            -undercolor -unique-colors -units -unsharp -verbose \
            -version -view -vignette -virtual-pixel -wave \
            -weight -white-point -white-threshold \
            -write' -- "$cur" ));
    else
        if [[ "$cur" == +* ]]; then
            COMPREPLY=($( compgen -W '+adjoin +append +compress \
            +contrast +debug +dither +endian +gamma +label +map \
            +mask +matte +negate +noise +page +raise +render \
            +write' -- "$cur" ));
        else
            _filedir;
        fi;
    fi
}
_count_args () 
{ 
    args=1;
    for ((i=1; i < COMP_CWORD; i++ ))
    do
        if [[ "${COMP_WORDS[i]}" != -* ]]; then
            args=$(($args+1));
        fi;
    done
}
_cpan2dist () 
{ 
    local cur prev packagelist cpandirs;
    COMPREPLY=();
    cur=`_get_cword`;
    prev=${COMP_WORDS[COMP_CWORD-1]};
    case $prev in 
        --format)
            COMPREPLY=($( compgen -W '$(perl -MCPANPLUS::Dist -e \
                "print map { \"\$_\n\" } CPANPLUS::Dist->dist_types")'                 -- "$cur" ));
            return 0
        ;;
        --@(banlist|ignorelist|modulelist|logfile))
            _filedir;
            return 0
        ;;
    esac;
    if [[ "$cur" == -* ]]; then
        COMPREPLY=($( compgen -W '--help --skiptest --force --install \
            --verbose --keepsource --makefile --buildprereq \
            --archive --flushcache --defaults --edit-metafile \
            --format --ban --banlist --ignore --ignorelist \
            --modulelist --logfile --timeout --set-config \
            --set-program --dist-opts --default-banlist \
            --default-ignorelist' -- $cur ));
    else
        cpandirs=("$HOME/.cpanplus/" "$HOME/.cpan/source/modules/");
        for dir in ${cpandirs[@]};
        do
            [ -d "$dir" -a -r "$dir/02packages.details.txt.gz" ] && packagelist="$dir/02packages.details.txt.gz";
        done;
        COMPREPLY=($( zgrep "^${cur//-/::}"             $packagelist 2>/dev/null             | awk '{print $1}' | sed -e 's/::/-/g' ));
    fi
}
_cpio () 
{ 
    local cur prev split=false;
    COMPREPLY=();
    cur=`_get_cword`;
    prev=${COMP_WORDS[COMP_CWORD-1]};
    _split_longopt && split=true;
    case $prev in 
        -H | --format)
            _cpio_format;
            return 0
        ;;
        -@(E|F|I|-?(pattern-)file))
            _filedir;
            return 0
        ;;
        -R | --owner)
            _usergroup;
            return 0
        ;;
        --rsh-command)
            COMPREPLY=($( compgen -c -- "$cur" ));
            return 0
        ;;
    esac;
    $split && return 0;
    if [ $COMP_CWORD -eq 1 ]; then
        COMPREPLY=($( compgen -W '-o --create -i --extract -p --pass-through' -- "$cur" ));
    else
        case ${COMP_WORDS[1]} in 
            -@(o|-create))
                if [[ "$cur" == -* ]]; then
                    COMPREPLY=($( compgen -W '-0 -a -c -v -A -B\
                        -L -V -C -H -M -O -F --file --format\
                        --message --null --reset-access-time\
                        --verbose --dot --append --block-size\
                        --dereference --io-size --quiet\
                        --force-local --rsh-command --help\
                        --version' -- "$cur" ));
                fi
            ;;
            -@(i|-extract))
                if [[ "$cur" == -* ]]; then
                    COMPREPLY=($( compgen -W '-b -c -d -f -m -n -r\
                        -t -s -u -v -B -S -V -C -E -H -M -R -I\
                        -F --file --make-directories\
                        --nonmatching\
                        --preserve-modification-time\
                        --numeric-uid-gid --rename -t --list\
                        --swap-bytes --swap --dot\
                        --unconditional --verbose --block-size\
                        --swap-halfwords --io-size\
                        --pattern-file --format --owner\
                        --no-preserve-owner --message\
                        --force-local --no-absolute-filenames\
                        --sparse --only-verify-crc --quiet\
                        --rsh-command --help\
                        --version' -- "$cur" ));
                fi
            ;;
            -@(p|-pass-through))
                if [[ "$cur" == -* ]]; then
                    COMPREPLY=($( compgen -W '-0 -a -d -l -m -u -v\
                        -L -V -R --null --reset-access-time\
                        --make-directories --link --quiet\
                        --preserve-modification-time\
                        --unconditional --verbose --dot\
                        --dereference --owner\
                        --no-preserve-owner --sparse --help\
                        --version' -- "$cur" ));
                else
                    _filedir -d;
                fi
            ;;
        esac;
    fi
}
_cpio_format () 
{ 
    COMPREPLY=($( compgen -W 'bin odc newc crc tar ustar hpbin hpodc' -- "$cur" ))
}
_createdb () 
{ 
    local cur prev split=false;
    COMPREPLY=();
    cur=`_get_cword`;
    prev=${COMP_WORDS[COMP_CWORD-1]};
    _split_longopt && split=true;
    case "$prev" in 
        -h | --host)
            _known_hosts_real "$cur";
            return 0
        ;;
        -U | --username | -O | --owner)
            _pg_users;
            return 0
        ;;
        -p | --port | -D | --tablespace | -E | --encoding | -T | --template)
            return 0
        ;;
        --help | --version)
            return 0
        ;;
    esac;
    $split && return 0;
    if [[ "$cur" == -* ]]; then
        COMPREPLY=($( compgen -W '-D -T -E -h -p -U -W -e -q \
            --tablespace --template --encoding --host --port \
            --username --password --echo --quiet --help --version' -- "$cur" ));
    else
        _pg_databases;
    fi
}
_cvs () 
{ 
    local cur count mode i cvsroot cvsroots pwd;
    local -a flags miss files entries changed newremoved;
    COMPREPLY=();
    cur=`_get_cword`;
    count=0;
    for i in "${COMP_WORDS[@]}";
    do
        [ $count -eq $COMP_CWORD ] && break;
        if [ "${COMP_WORDS[((count))]}" == "$cvsroot" -a "$mode" == "cvsroot" ]; then
            mode="";
        fi;
        if [ -z "$mode" ]; then
            case $i in 
                -d)
                    mode=cvsroot;
                    cvsroot=${COMP_WORDS[((count+1))]}
                ;;
                @(ad?(d)|new))
                    mode=add
                ;;
                @(adm?(in)|rcs))
                    mode=admin
                ;;
                ann?(notate))
                    mode=annotate
                ;;
                @(checkout|co|get))
                    mode=checkout
                ;;
                @(com?(mit)|ci))
                    mode=commit
                ;;
                di?(f?(f)))
                    mode=diff
                ;;
                ex?(p?(ort)))
                    mode=export
                ;;
                ?(un)edit)
                    mode=$i
                ;;
                hi?(s?(tory)))
                    mode=history
                ;;
                im?(p?(ort)))
                    mode=import
                ;;
                re?(l?(ease)))
                    mode=release
                ;;
                ?(r)log)
                    mode=log
                ;;
                @(rdiff|patch))
                    mode=rdiff
                ;;
                @(remove|rm|delete))
                    mode=remove
                ;;
                @(rtag|rfreeze))
                    mode=rtag
                ;;
                st?(at?(us)))
                    mode=status
                ;;
                @(tag|freeze))
                    mode=tag
                ;;
                up?(d?(ate)))
                    mode=update
                ;;
                *)

                ;;
            esac;
        else
            if [[ "$i" = -* ]]; then
                flags=("${flags[@]}" $i);
            fi;
        fi;
        count=$((++count));
    done;
    case "$mode" in 
        add)
            if [[ "$cur" != -* ]]; then
                set_prefix;
                if [ $COMP_CWORD -gt 1 -a -r ${prefix:-}CVS/Entries ]; then
                    get_entries;
                    [ -z "$cur" ] && files=$( command ls -Ad !(CVS) ) || files=$( command ls -d ${cur}* 2>/dev/null );
                    for i in "${entries[@]}";
                    do
                        files=(${files[@]/#$i//});
                    done;
                    COMPREPLY=($( compgen -X '*~' -W '${files[@]}' -- $cur ));
                fi;
            else
                COMPREPLY=($( compgen -W '-k -m' -- "$cur" ));
            fi
        ;;
        admin)
            if [[ "$cur" = -* ]]; then
                COMPREPLY=($( compgen -W '-i -a -A -e -b -c -k -l -u -L -U -m -M \
                    -n -N -o -q -I -s -t -t- -T -V -x -z' -- $cur ));
            fi
        ;;
        annotate)
            if [[ "$cur" = -* ]]; then
                COMPREPLY=($( compgen -W '-D -F -f -l -R -r' -- "$cur" ));
            else
                get_entries;
                COMPREPLY=($( compgen -W '${entries[@]}' -- "$cur" ));
            fi
        ;;
        checkout)
            if [[ "$cur" != -* ]]; then
                [ -z "$cvsroot" ] && cvsroot=$CVSROOT;
                COMPREPLY=($( cvs -d "$cvsroot" co -c 2> /dev/null |                     awk '{print $1}' ));
                COMPREPLY=($( compgen -W '${COMPREPLY[@]}' -- "$cur" ));
            else
                COMPREPLY=($( compgen -W '-A -N -P -R -c -f -l -n -p \
                    -s -r -D -d -k -j' -- "$cur" ));
            fi
        ;;
        commit)
            set_prefix;
            if [[ "$cur" != -* ]] && [ -r ${prefix:-}CVS/Entries ]; then
                if [ -n "${COMP_CVS_REMOTE:-}" ]; then
                    changed=($( cvs -q diff --brief 2>&1 |                 sed -ne 's/^Files [^ ]* and \([^ ]*\) differ$/\1/p' ));
                    newremoved=($( cvs -q diff --brief 2>&1 |                 sed -ne 's/^cvs diff: \([^ ]*\) .*, no comparison available$/\1/p' ));
                    COMPREPLY=($( compgen -W '${changed[@]:-} \
                           ${newremoved[@]:-}' -- "$cur" ));
                else
                    COMPREPLY=($(compgen $default -- "$cur"));
                fi;
            else
                COMPREPLY=($( compgen -W '-n -R -l -f -F -m -r' -- $cur ));
            fi
        ;;
        cvsroot)
            if [ -r ~/.cvspass ]; then
                cvsroots=$( sed 's/^[^ ]* //; s/:/\\:/g' ~/.cvspass );
                COMPREPLY=($( compgen -W '$cvsroots' -- "$cur" ));
            fi
        ;;
        export)
            if [[ "$cur" != -* ]]; then
                [ -z "$cvsroot" ] && cvsroot=$CVSROOT;
                COMPREPLY=($( cvs -d "$cvsroot" co -c | awk '{print $1}' ));
                COMPREPLY=($( compgen -W '${COMPREPLY[@]}' -- "$cur" ));
            else
                COMPREPLY=($( compgen -W '-N -f -l -R -n -r -D -d -k'                     -- "$cur" ));
            fi
        ;;
        diff)
            if [[ "$cur" == -* ]]; then
                _longopt diff;
            else
                get_entries;
                COMPREPLY=($( compgen -W '${entries[@]:-}' -- "$cur" ));
            fi
        ;;
        remove)
            if [[ "$cur" != -* ]]; then
                set_prefix;
                if [ $COMP_CWORD -gt 1 -a -r ${prefix:-}CVS/Entries ]; then
                    get_entries;
                    for i in "${entries[@]}";
                    do
                        [ ! -r "$i" ] && miss=("${miss[@]}" $i);
                    done;
                    COMPREPLY=($(compgen -W '${miss[@]:-}' -- "$cur"));
                fi;
            else
                COMPREPLY=($( compgen -W '-f -l -R' -- "$cur" ));
            fi
        ;;
        import)
            if [[ "$cur" != -* ]]; then
                [ -z "$cvsroot" ] && cvsroot=$CVSROOT;
                prefix=${cur%/*};
                if [ -r ${cvsroot}/${prefix} ]; then
                    get_modules;
                    COMPREPLY=(${COMPREPLY[@]#$cvsroot});
                    COMPREPLY=(${COMPREPLY[@]#\/});
                fi;
                pwd=$( pwd );
                pwd=${pwd##*/};
                COMPREPLY=($( compgen -W '${COMPREPLY[@]} $pwd' -- $cur ));
            else
                COMPREPLY=($( compgen -W '-d -k -I -b -m -W' -- "$cur" ));
            fi
        ;;
        update)
            if [[ "$cur" = -* ]]; then
                COMPREPLY=($( compgen -W '-A -P -C -d -f -l -R -p \
                    -k -r -D -j -I -W' -- "$cur" ));
            fi
        ;;
        "")
            COMPREPLY=($( compgen -W 'add admin annotate checkout ci co \
                commit diff delete edit export \
                freeze get history import log new \
                patch rcs rdiff release remove \
                rfreeze rlog rm rtag stat status \
                tag unedit up update -H -Q -q -b \
                -d -e -f -l -n -t -r -v -w -x -z \
                --help --version' -- "$cur" ))
        ;;
        *)

        ;;
    esac;
    return 0
}
_dd () 
{ 
    local cur;
    COMPREPLY=();
    cur=`_get_cword =`;
    case "$cur" in 
        if=* | of=*)
            cur=${cur#*=};
            _filedir;
            return 0
        ;;
        conv=*)
            cur=${cur#*=};
            COMPREPLY=($( compgen -W 'ascii ebcdic ibm block unblock \
            lcase notrunc ucase swab noerror sync' -- "$cur" ));
            return 0
        ;;
    esac;
    _expand || return 0;
    COMPREPLY=($( compgen -W '--help --version' -- "$cur" ) $( compgen -W 'bs cbs conv count ibs if obs of seek skip'                -S '=' -- "$cur" ))
}
_debconf_show () 
{ 
    local cur;
    COMPREPLY=();
    cur=${COMP_WORDS[COMP_CWORD]};
    COMPREPLY=($( compgen -W '--listowners --listdbs --db=' -- $cur ) $( apt-cache pkgnames -- $cur ))
}
_desktop_file_validate () 
{ 
    COMPRELY=();
    cur=${COMP_WORDS[COMP_CWORD]};
    _filedir '@(desktop)'
}
_dfutool () 
{ 
    local cur prev;
    COMPREPLY=();
    cur=`_get_cword`;
    prev=${COMP_WORDS[COMP_CWORD-1]};
    case $prev in 
        -@(d|-device))
            _bluetooth_devices;
            return 0
        ;;
    esac;
    if [[ "$cur" == -* ]]; then
        COMPREPLY=($( compgen -W '-h --help -d --device' -- "$cur" ));
    else
        _count_args;
        case $args in 
            1)
                COMPREPLY=($( compgen -W 'verify modify \
                    upgrade archive' -- "$cur" ))
            ;;
            2)
                _filedir
            ;;
        esac;
    fi
}
_dhclient () 
{ 
    local cur prev;
    COMPREPLY=();
    cur=`_get_cword`;
    prev=${COMP_WORDS[COMP_CWORD-1]};
    case "$prev" in 
        -@(cf|lf|pf|sf))
            _filedir;
            return 0
        ;;
        -s)
            _known_hosts_real "$cur";
            return 0
        ;;
    esac;
    if [[ "$cur" == -* ]]; then
        COMPREPLY=($( compgen -W '-p -d -q -1 -r -lf -pf \
            -cf -sf -s -g -n -nw -w' -- "$cur" ));
    else
        _available_interfaces;
    fi
}
_display () 
{ 
    local cur;
    COMPREPLY=();
    cur=`_get_cword`;
    _ImageMagick;
    if [[ "$cur" == -* ]]; then
        COMPREPLY=($( compgen -W '-alpha -antialias -authenticate \
            -auto-orient -backdrop -background -border \
            -bordercolor -borderwidth -channel -clip \
            -clip-path -coalesce -colormap -colors -colorspace \
            -comment -compress -contrast -crop -debug -decipher \
            -define -delay -density -depth -despeckle -display \
            -dispose -dither -edge -endian -enhance -extract \
            -filter -flatten -flip -flop -font -foreground \
            -format -frame -gamma -geometry -help -iconGeometry \
            -iconic -identify -immutable -interlace -interpolate \
            -label -limit -list -log -loop -map -mattecolor \
            -monitor -monochrome -name -negate -page -profile \
            -quality -quantize -quiet -raise -regard-warnings \
            -remote -repage -resample -resize \
            -respect-parenthesis -roll -rotate -sample \
            -sampling-factor -scenes -seed -segment -set \
            -shared-memory -sharpen -size -strip -texture -title \
            -transparent-color -treedepth -trim -update \
            -usePixmap -verbose -version -virtual-pixel -visual \
            -window -window-group -write' -- "$cur" ));
    else
        if [[ "$cur" == +* ]]; then
            COMPREPLY=($( compgen -W '+compress +contrast +debug +dither \
            +endian +gamma +label +map +matte +negate +page \
            +raise +write' -- "$cur" ));
        else
            _filedir;
        fi;
    fi
}
_dpkg () 
{ 
    local cur prev i;
    COMPREPLY=();
    cur=`_get_cword`;
    prev=${COMP_WORDS[COMP_CWORD-1]};
    i=$COMP_CWORD;
    _expand || return 0;
    _split_longopt;
    if [[ $cur != -* ]]; then
        while [[ $prev != -* && $i != 1 ]]; do
            i=$((i-1));
            prev=${COMP_WORDS[i-1]};
        done;
    fi;
    case "$prev" in 
        -@(c|i|A|I|f|e|x|X|W|-@(install|unpack|record-avail|contents|info|fsys-tarfile|field|control|extract|show)))
            _filedir '?(u)deb';
            return 0
        ;;
        -@(b|-build))
            _filedir -d;
            return 0
        ;;
        -@(s|p|l|-@(status|print-avail|list)))
            COMPREPLY=($( apt-cache pkgnames "$cur" 2>/dev/null ));
            return 0
        ;;
        -@(S|-search))
            _filedir;
            return 0
        ;;
        -@(r|L|P|-@(remove|purge|listfiles)))
            COMPREPLY=($( _comp_dpkg_installed_packages "$cur" ));
            return 0
        ;;
        *)
            COMPREPLY=($( compgen -W '-i --install --unpack -A --record-avail \
                --configure -r --remove -P --purge --get-selections \
                --set-selections --update-avail --merge-avail \
                --clear-avail  --command-fd --forget-old-unavail -s \
                --status -p --print-avail -L --listfiles -l --list \
                -S --search -C --audit --print-architecture \
                --print-gnu-build-architecture \
                --print-installation-architecture \
                --compare-versions --help --version --force-help \
                --force-all --force-auto-select --force-downgrade \
                --force-configure-any --force-hold --force-bad-path \
                --force-not-root --force-overwrite \
                --force-overwrite-diverted --force-bad-verify \
                --force-depends-version --force-depends \
                --force-confnew --force-confold --force-confdef \
                --force-confmiss --force-conflicts --force-architecture\
                --force-overwrite-dir --force-remove-reinstreq \
                --force-remove-essential -Dh \
                --debug=help --licence --admindir --root --instdir \
                -O --selected-only -E --skip-same-version \
                -G --refuse-downgrade -B --auto-deconfigure \
                --no-debsig --no-act -D --debug --status-fd \
                -b --build -I --info -f --field -c --contents \
                -x --extract -X --vextract --fsys-tarfile -e --control \
                --ignore-depends --abort-after' -- "$cur" ))
        ;;
    esac
}
_dpkg_reconfigure () 
{ 
    local cur prev opt;
    COMPREPLY=();
    cur=`_get_cword`;
    prev=${COMP_WORDS[COMP_CWORD-1]};
    case "$prev" in 
        -@(f|-frontend))
            opt=($( echo /usr/share/perl5/Debconf/FrontEnd/* ));
            opt=(${opt[@]##*/});
            opt=(${opt[@]%.pm});
            COMPREPLY=($( compgen -W '${opt[@]}' -- "$cur" ));
            return 0
        ;;
        -@(p|-priority))
            COMPREPLY=($( compgen -W 'low medium high critical' -- "$cur" ));
            return 0
        ;;
    esac;
    if [[ "$cur" == -* ]]; then
        COMPREPLY=($( compgen -W '-f --frontend -p --priority -a --all -u \
            --unseen-only -h --help -s --showold --force --terse' -- "$cur" ));
    else
        COMPREPLY=($( _comp_dpkg_installed_packages "$cur" ));
    fi
}
_dpkg_source () 
{ 
    local cur prev options work i action packopts unpackopts;
    packopts="-c -l -F -V -T -D -U -W -E -sa -i -I -sk -sp -su -sr -ss -sn -sA -sK -sP -sU -sR";
    unpackopts="-sp -sn -su";
    options=`echo "-x -b $packopts $unpackopts" | xargs echo | sort -u | xargs echo`;
    COMPREPLY=();
    if [ "$1" != "dpkg-source" ]; then
        return 1;
    fi;
    cur=`_get_cword`;
    prev=${COMP_WORDS[COMP_CWORD-1]};
    action="options";
    for ((i=0; i < ${#COMP_WORDS[@]}-1; i++ ))
    do
        if [[ ${COMP_WORDS[$i]} == "-x" ]]; then
            action=unpack;
        else
            if [[ ${COMP_WORDS[$i]} == "-b" ]]; then
                action=pack;
            else
                if [[ ${COMP_WORDS[$i]} == "-h" ]]; then
                    action=help;
                fi;
            fi;
        fi;
    done;
    for i in $options;
    do
        if [ "$cur" = "$i" ]; then
            COMPREPLY=("$cur");
            return 0;
        fi;
    done;
    case "$action" in 
        "unpack")
            if [ "$cur" = "-" -o "$cur" = "-s" ]; then
                COMPREPLY=($unpackopts);
                return 0;
            fi;
            case "$prev" in 
                "-x")
                    COMPREPLY=($( compgen -d -- "$cur" ) $( compgen -f -X '!*.dsc' -- "$cur" ));
                    return 0
                ;;
                *)
                    COMPREPLY=($unpackopts $(compgen -d -f -- "$cur" ));
                    return 0
                ;;
            esac;
            return 0
        ;;
        "pack")
            if [ "$cur" = "-" ]; then
                COMPREPLY=($packopts);
                return 0;
            fi;
            if [ "$cur" = "-s" ]; then
                COMPREPLY=("-sa" "-sk" "-sp" "-su" "-sr" "-ss" "-sn" "-sA" "-sK" "-sP" "-sU" "-sR");
                return 0;
            fi;
            case "$prev" in 
                "-b")
                    COMPREPLY=($( compgen -d -- "$cur" ));
                    return 0
                ;;
                "-c" | "-l" | "-T" | "-i" | "-I")
                    COMPREPLY=($( compgen -d -f ));
                    return 0
                ;;
                "-F")
                    COMPREPLY=($( ( cd /usr/lib/dpkg/parsechangelog; compgen -f "$cur" ) ));
                    return 0
                ;;
                "-V" | "-D")
                    COMPREPLY=();
                    return 0
                ;;
                "-D")
                    if echo -- "$cur" | grep --color=auto -q "="; then
                        COMPREPLY=();
                        return 0;
                    else
                        COMPREPLY=(Format Source Version Binary Maintainer Uploader Architecture Standards-Version Build-Depends Files);
                        return 0;
                    fi
                ;;
                "-U")
                    COMPREPLY=(Format Source Version Binary Maintainer Uploader Architecture Standards-Version Build-Depends Files);
                    return 0
                ;;
                *)
                    COMPREPLY=($packopts);
                    return 0
                ;;
            esac;
            return 0
        ;;
        *)
            if [ "$cur" = "-s" ]; then
                COMPREPLY=("-sa" "-sk" "-sp" "-su" "-sr" "-ss" "-sn" "-sA" "-sK" "-sP" "-sU" "-sR");
                return 0;
            fi;
            COMPREPLY=($options);
            return 0
        ;;
    esac
}
_dropdb () 
{ 
    local cur prev split=false;
    COMPREPLY=();
    cur=`_get_cword`;
    prev=${COMP_WORDS[COMP_CWORD-1]};
    _split_longopt && split=true;
    case "$prev" in 
        -h | --host)
            _known_hosts_real "$cur";
            return 0
        ;;
        -U | --username)
            _pg_users;
            return 0
        ;;
        --help | --version)
            return 0
        ;;
    esac;
    $split && return 0;
    if [[ "$cur" == -* ]]; then
        COMPREPLY=($( compgen -W '-h -p -U -W -i -e -q \
            --host --port --username --password --interactive \
            --echo --quiet --help --version' -- "$cur" ));
    else
        _pg_databases;
    fi
}
_dselect () 
{ 
    local cur prev;
    COMPREPLY=();
    cur=`_get_cword`;
    prev=${COMP_WORDS[COMP_CWORD-1]};
    case "$prev" in 
        --admindir)
            _filedir -d;
            return 0
        ;;
        -@(D|debug))
            _filedir;
            return 0
        ;;
    esac;
    if [[ "$cur" == -* ]]; then
        COMPREPLY=($( compgen -W '--admindir --help --version --licence \
            --license --expert --debug' -- "$cur" ));
    else
        COMPREPLY=($( compgen -W 'access update select install config \
            remove quit' -- "$cur" ));
    fi;
    return 0
}
_expand () 
{ 
    if [[ "$cur" == \~*/* ]]; then
        eval cur=$cur;
    else
        if [[ "$cur" == \~* ]]; then
            cur=${cur#\~};
            COMPREPLY=($( compgen -P '~' -u "$cur" ));
            [ ${#COMPREPLY[@]} -eq 1 ] && eval COMPREPLY[0]=${COMPREPLY[0]};
            return ${#COMPREPLY[@]};
        fi;
    fi
}
_export () 
{ 
    local cur;
    COMPREPLY=();
    cur=`_get_cword`;
    case "$COMP_LINE" in 
        *=\$*)
            COMPREPLY=($( compgen -v -P '$' -- "${cur#*=\$}" ))
        ;;
        *[^=])
            COMPREPLY=($( compgen -v -S '=' -- "$cur" ))
        ;;
        *=)
            COMPREPLY=("$( eval echo -n \"$`echo ${cur%=}`\" |
                ( echo -n \'
                  sed -e 's/'\''/'\''\\\'\'''\''/g'
                  echo -n \' ) )")
        ;;
    esac
}
_faillog () 
{ 
    local cur prev split=false;
    COMPREPLY=();
    cur=`_get_cword`;
    prev=${COMP_WORDS[COMP_CWORD-1]};
    _split_longopt && split=true;
    case "$prev" in 
        -h | --help | -l | --lock-time | -m | --maximum | -t | --time)
            return 0
        ;;
        -u | --user)
            COMPREPLY=($( compgen -u -- "$cur" ));
            return 0
        ;;
    esac;
    $split && return 0;
    if [[ "$cur" == -* ]]; then
        COMPREPLY=($( compgen -W '-a --all -h --help -l --lock-time \
            -m --maximum -r --reset -t --time -u --user' -- "$cur" ));
        return 0;
    fi
}
_filedir () 
{ 
    local IFS='	
' xspec;
    xspec=${1:+"!*.$1"};
    COMPREPLY=(${COMPREPLY[@]:-} $( compgen -f -X "$xspec" -- "$cur" ) $( compgen -d -- "$cur" ))
}
_filedir_xspec () 
{ 
    local IFS cur xspec;
    IFS='	
';
    COMPREPLY=();
    cur=`_get_cword`;
    _expand || return 0;
    xspec=$( sed -ne '/^complete .*[ 	]'${1##*/}'\([ 	]\|$\)/{p;q;}'         $BASH_COMPLETION );
    xspec=${xspec#*-X };
    xspec=${xspec%% *};
    local -a toks;
    local tmp;
    toks=(${toks[@]-} $(
        compgen -d -- "$(quote_readline "$cur")" | {
        while read -r tmp; do
            # see long TODO comment in _filedir() --David
            echo $tmp
        done
        }
        ));
    toks=(${toks[@]-} $(
        eval compgen -f -X "$xspec" -- "\$(quote_readline "\$cur")" | {
        while read -r tmp; do
            [ -n $tmp ] && echo $tmp
        done
        }
        ));
    COMPREPLY=("${toks[@]}")
}
_find () 
{ 
    local cur prev i exprfound onlyonce;
    COMPREPLY=();
    cur=`_get_cword`;
    prev=${COMP_WORDS[COMP_CWORD-1]};
    case "$prev" in 
        -@(max|min)depth)
            COMPREPLY=($( compgen -W '0 1 2 3 4 5 6 7 8 9' -- "$cur" ));
            return 0
        ;;
        -?(a|c)newer | -fls | -fprint?(0|f) | -?(i)?(l)name | -?(i)wholename)
            _filedir;
            return 0
        ;;
        -fstype)
            [ -e /proc/filesystems ] && COMPREPLY=($( compgen -W "$( cut -d'	' -f2 /proc/filesystems )"             -- "$cur" ));
            return 0
        ;;
        -gid)
            _gids;
            return 0
        ;;
        -group)
            if [ -n "$bash205" ]; then
                COMPREPLY=($( compgen -g -- $cur 2>/dev/null));
            fi;
            return 0
        ;;
        -?(x)type)
            COMPREPLY=($( compgen -W 'b c d p f l s' -- "$cur" ));
            return 0
        ;;
        -uid)
            _uids;
            return 0
        ;;
        -user)
            COMPREPLY=($( compgen -u -- "$cur" ));
            return 0
        ;;
        -exec | -ok)
            COMP_WORDS=(COMP_WORDS[0] "$cur");
            COMP_CWORD=1;
            _command;
            return 0
        ;;
        -[acm]min | -[acm]time | -?(i)?(l)?(whole)name | -inum | -?(i)path | -?(i)regex | -links | -perm | -size | -used | -printf)
            return 0
        ;;
    esac;
    _expand || return 0;
    for i in ${COMP_WORDS[@]};
    do
        [[ "$i" = [-\(\),\!]* ]] && exprfound=1 && break;
    done;
    if [ "$exprfound" != 1 ] && [[ "$cur" != [-\(\),\!]* ]]; then
        _filedir -d;
        return 0;
    fi;
    COMPREPLY=($( compgen -W '-daystart -depth -follow -help -maxdepth \
        -mindepth -mount -noleaf -version -xdev -amin -anewer \
        -atime -cmin -cnewer -ctime -empty -false -fstype \
        -gid -group -ilname -iname -inum -ipath -iregex \
        -wholename \
        -links -lname -mmin -mtime -name -newer -nouser \
        -nogroup -perm -regex -size -true -type -uid -used \
        -user -xtype -exec -fls -fprint -fprint0 -fprintf -ok \
        -print -print0 -printf -prune -ls -wholename -iwholename' -- "$cur" ));
    onlyonce=' -daystart -depth -follow -help -maxdepth -mindepth -mount \
       -noleaf -version -xdev ';
    COMPREPLY=($( echo "${COMP_WORDS[@]}" |            (while read -d ' ' i; do
            [ "$i" == "" ] ||
            [ "${onlyonce/ ${i%% *} / }" == "$onlyonce" ] &&
            continue
            # flatten array with spaces on either side,
            # otherwise we cannot grep on word boundaries of
            # first and last word
            COMPREPLY=" ${COMPREPLY[@]} "
            # remove word from list of completions
            COMPREPLY=( ${COMPREPLY/ ${i%% *} / } )
            done
            echo "${COMPREPLY[@]}")
          ));
    _filedir;
    return 0
}
_function () 
{ 
    local cur prev;
    COMPREPLY=();
    cur=`_get_cword`;
    prev=${COMP_WORDS[COMP_CWORD-1]};
    if [[ $1 == @(declare|typeset) ]]; then
        if [ "$prev" = -f ]; then
            COMPREPLY=($( compgen -A function -- "$cur" ));
        else
            if [[ "$cur" == -* ]]; then
                COMPREPLY=($( compgen -W '-a -f -F -i -r -x -p' -- "$cur" ));
            fi;
        fi;
    else
        if [ $COMP_CWORD -eq 1 ]; then
            COMPREPLY=($( compgen -A function -- "$cur" ));
        else
            COMPREPLY=("() $( type -- ${COMP_WORDS[1]} | sed -e 1,2d )");
        fi;
    fi
}
_gcc () 
{ 
    local cur cc backend;
    COMPREPLY=();
    cur=`_get_cword`;
    _expand || return 0;
    case "$1" in 
        gcj)
            backend=jc1
        ;;
        gpc)
            backend=gpc1
        ;;
        *77)
            backend=f771
        ;;
        *)
            backend=cc1
        ;;
    esac;
    if [[ "$cur" == -* ]]; then
        cc=$( $1 -print-prog-name=$backend );
        COMPREPLY=($( compgen -W "$( $cc --help 2>/dev/null |            tr '\t' ' ' |            sed -e '/^  *-/!d' -e 's/ *-\([^ ]*\).*/-\1/' |            sort -u )" -- "$cur" ));
    else
        _filedir;
    fi
}
_gdb () 
{ 
    local cur prev;
    COMPREPLY=();
    cur=`_get_cword`;
    prev=${COMP_WORDS[COMP_CWORD-1]};
    if [ $COMP_CWORD -eq 1 ]; then
        local IFS;
        if [[ "$cur" == */* ]]; then
            IFS='
';
            COMPREPLY=($( PATH="$PATH:." compgen -d -c -- "$cur" ));
        else
            IFS=":";
            local path_array=($(echo "$PATH" | sed 's/::\+/:/g;s/^:\|:$//g'));
            IFS='
';
            COMPREPLY=($( compgen -d -W '$(find "${path_array[@]}" . \
                -mindepth 1 -maxdepth 1 -not -type d -executable \
                -printf "%f\\n" 2>/dev/null)' -- "$cur" ));
        fi;
    else
        if [ $COMP_CWORD -eq 2 ]; then
            prev=${prev##*/};
            COMPREPLY=($( compgen -fW "$( command ps axo comm,pid |             awk '{if ($1 ~ /^'"$prev"'/) print $2}' )" -- "$cur" ));
        fi;
    fi
}
_get_command () 
{ 
    local i;
    command=;
    for ((i=1; i < COMP_CWORD; i++ ))
    do
        if [[ "${COMP_WORDS[i]}" != -* ]]; then
            command=${COMP_WORDS[i]};
            break;
        fi;
    done
}
_get_cword () 
{ 
    if [ -n "$bash4" ]; then
        __get_cword4 "$@";
    else
        __get_cword3;
    fi
}
_getent () 
{ 
    local cur prev;
    COMPREPLY=();
    cur=`_get_cword`;
    prev=${COMP_WORDS[COMP_CWORD-1]};
    case $prev in 
        passwd)
            COMPREPLY=($( compgen -u "$cur"  ));
            return 0
        ;;
        group)
            COMPREPLY=($( compgen -g "$cur"  ));
            return 0
        ;;
        services)
            COMPREPLY=($( compgen -s "$cur"  ));
            return 0
        ;;
        hosts)
            COMPREPLY=($( compgen -A hostname "$cur"  ));
            return 0
        ;;
        protocols | networks | ahosts | ahostsv4 | ahostsv6 | rpc)
            COMPREPLY=($( compgen -W "$( getent "$prev" |                 awk '{ print $1 }' )" -- "$cur" ));
            return 0
        ;;
        aliases | shadow)
            COMPREPLY=($( compgen -W "$( getent "$prev" | cut -d: -f1 )"                 -- "$cur" ));
            return 0
        ;;
    esac;
    if [ $COMP_CWORD -eq 1 ]; then
        COMPREPLY=($( compgen -W 'passwd group hosts services protocols \
            networks ahosts ahostsv4 ahostsv6 aliases ethers netgroup rpc \
            shadow' -- "$cur" ));
    fi
}
_gids () 
{ 
    if type getent &>/dev/null; then
        COMPREPLY=($( compgen -W '$( getent group | cut -d: -f3 )'             -- "$cur" ));
    else
        if type perl &>/dev/null; then
            COMPREPLY=($( compgen -W '$( perl -e '"'"'while (($gid) = (getgrent)[2]) { print $gid . "\n" }'"'"' )' -- "$cur" ));
        else
            COMPREPLY=($( compgen -W '$( cut -d: -f3 /etc/group )' -- "$cur" ));
        fi;
    fi
}
_git () 
{ 
    local i c=1 command __git_dir;
    while [ $c -lt $COMP_CWORD ]; do
        i="${COMP_WORDS[c]}";
        case "$i" in 
            --git-dir=*)
                __git_dir="${i#--git-dir=}"
            ;;
            --bare)
                __git_dir="."
            ;;
            --version | -p | --paginate)

            ;;
            --help)
                command="help";
                break
            ;;
            *)
                command="$i";
                break
            ;;
        esac;
        c=$((++c));
    done;
    if [ -z "$command" ]; then
        case "${COMP_WORDS[COMP_CWORD]}" in 
            --*)
                __gitcomp "
			--paginate
			--no-pager
			--git-dir=
			--bare
			--version
			--exec-path
			--html-path
			--work-tree=
			--help
			"
            ;;
            *)
                __git_compute_porcelain_commands;
                __gitcomp "$__git_porcelain_commands $(__git_aliases)"
            ;;
        esac;
        return;
    fi;
    local expansion=$(__git_aliased_command "$command");
    [ "$expansion" ] && command="$expansion";
    case "$command" in 
        am)
            _git_am
        ;;
        add)
            _git_add
        ;;
        apply)
            _git_apply
        ;;
        archive)
            _git_archive
        ;;
        bisect)
            _git_bisect
        ;;
        bundle)
            _git_bundle
        ;;
        branch)
            _git_branch
        ;;
        checkout)
            _git_checkout
        ;;
        cherry)
            _git_cherry
        ;;
        cherry-pick)
            _git_cherry_pick
        ;;
        clean)
            _git_clean
        ;;
        clone)
            _git_clone
        ;;
        commit)
            _git_commit
        ;;
        config)
            _git_config
        ;;
        describe)
            _git_describe
        ;;
        diff)
            _git_diff
        ;;
        difftool)
            _git_difftool
        ;;
        fetch)
            _git_fetch
        ;;
        format-patch)
            _git_format_patch
        ;;
        fsck)
            _git_fsck
        ;;
        gc)
            _git_gc
        ;;
        grep)
            _git_grep
        ;;
        help)
            _git_help
        ;;
        init)
            _git_init
        ;;
        log)
            _git_log
        ;;
        ls-files)
            _git_ls_files
        ;;
        ls-remote)
            _git_ls_remote
        ;;
        ls-tree)
            _git_ls_tree
        ;;
        merge)
            _git_merge
        ;;
        mergetool)
            _git_mergetool
        ;;
        merge-base)
            _git_merge_base
        ;;
        mv)
            _git_mv
        ;;
        name-rev)
            _git_name_rev
        ;;
        notes)
            _git_notes
        ;;
        pull)
            _git_pull
        ;;
        push)
            _git_push
        ;;
        rebase)
            _git_rebase
        ;;
        remote)
            _git_remote
        ;;
        replace)
            _git_replace
        ;;
        reset)
            _git_reset
        ;;
        revert)
            _git_revert
        ;;
        rm)
            _git_rm
        ;;
        send-email)
            _git_send_email
        ;;
        shortlog)
            _git_shortlog
        ;;
        show)
            _git_show
        ;;
        show-branch)
            _git_show_branch
        ;;
        stash)
            _git_stash
        ;;
        stage)
            _git_add
        ;;
        submodule)
            _git_submodule
        ;;
        svn)
            _git_svn
        ;;
        tag)
            _git_tag
        ;;
        whatchanged)
            _git_log
        ;;
        *)
            COMPREPLY=()
        ;;
    esac
}
_git_add () 
{ 
    __git_has_doubledash && return;
    local cur="${COMP_WORDS[COMP_CWORD]}";
    case "$cur" in 
        --*)
            __gitcomp "
			--interactive --refresh --patch --update --dry-run
			--ignore-errors --intent-to-add
			";
            return
        ;;
    esac;
    COMPREPLY=()
}
_git_am () 
{ 
    local cur="${COMP_WORDS[COMP_CWORD]}" dir="$(__gitdir)";
    if [ -d "$dir"/rebase-apply ]; then
        __gitcomp "--skip --continue --resolved --abort";
        return;
    fi;
    case "$cur" in 
        --whitespace=*)
            __gitcomp "$__git_whitespacelist" "" "${cur##--whitespace=}";
            return
        ;;
        --*)
            __gitcomp "
			--3way --committer-date-is-author-date --ignore-date
			--ignore-whitespace --ignore-space-change
			--interactive --keep --no-utf8 --signoff --utf8
			--whitespace= --scissors
			";
            return
        ;;
    esac;
    COMPREPLY=()
}
_git_apply () 
{ 
    local cur="${COMP_WORDS[COMP_CWORD]}";
    case "$cur" in 
        --whitespace=*)
            __gitcomp "$__git_whitespacelist" "" "${cur##--whitespace=}";
            return
        ;;
        --*)
            __gitcomp "
			--stat --numstat --summary --check --index
			--cached --index-info --reverse --reject --unidiff-zero
			--apply --no-add --exclude=
			--ignore-whitespace --ignore-space-change
			--whitespace= --inaccurate-eof --verbose
			";
            return
        ;;
    esac;
    COMPREPLY=()
}
_git_archive () 
{ 
    local cur="${COMP_WORDS[COMP_CWORD]}";
    case "$cur" in 
        --format=*)
            __gitcomp "$(git archive --list)" "" "${cur##--format=}";
            return
        ;;
        --remote=*)
            __gitcomp "$(__git_remotes)" "" "${cur##--remote=}";
            return
        ;;
        --*)
            __gitcomp "
			--format= --list --verbose
			--prefix= --remote= --exec=
			";
            return
        ;;
    esac;
    __git_complete_file
}
_git_bisect () 
{ 
    __git_has_doubledash && return;
    local subcommands="start bad good skip reset visualize replay log run";
    local subcommand="$(__git_find_on_cmdline "$subcommands")";
    if [ -z "$subcommand" ]; then
        __gitcomp "$subcommands";
        return;
    fi;
    case "$subcommand" in 
        bad | good | reset | skip)
            __gitcomp "$(__git_refs)"
        ;;
        *)
            COMPREPLY=()
        ;;
    esac
}
_git_branch () 
{ 
    local i c=1 only_local_ref="n" has_r="n";
    while [ $c -lt $COMP_CWORD ]; do
        i="${COMP_WORDS[c]}";
        case "$i" in 
            -d | -m)
                only_local_ref="y"
            ;;
            -r)
                has_r="y"
            ;;
        esac;
        c=$((++c));
    done;
    case "${COMP_WORDS[COMP_CWORD]}" in 
        --*)
            __gitcomp "
			--color --no-color --verbose --abbrev= --no-abbrev
			--track --no-track --contains --merged --no-merged
			"
        ;;
        *)
            if [ $only_local_ref = "y" -a $has_r = "n" ]; then
                __gitcomp "$(__git_heads)";
            else
                __gitcomp "$(__git_refs)";
            fi
        ;;
    esac
}
_git_bundle () 
{ 
    local cmd="${COMP_WORDS[2]}";
    case "$COMP_CWORD" in 
        2)
            __gitcomp "create list-heads verify unbundle"
        ;;
        3)

        ;;
        *)
            case "$cmd" in 
                create)
                    __git_complete_revlist
                ;;
            esac
        ;;
    esac
}
_git_checkout () 
{ 
    __git_has_doubledash && return;
    local cur="${COMP_WORDS[COMP_CWORD]}";
    case "$cur" in 
        --conflict=*)
            __gitcomp "diff3 merge" "" "${cur##--conflict=}"
        ;;
        --*)
            __gitcomp "
			--quiet --ours --theirs --track --no-track --merge
			--conflict= --patch
			"
        ;;
        *)
            __gitcomp "$(__git_refs)"
        ;;
    esac
}
_git_cherry () 
{ 
    __gitcomp "$(__git_refs)"
}
_git_cherry_pick () 
{ 
    local cur="${COMP_WORDS[COMP_CWORD]}";
    case "$cur" in 
        --*)
            __gitcomp "--edit --no-commit"
        ;;
        *)
            __gitcomp "$(__git_refs)"
        ;;
    esac
}
_git_clean () 
{ 
    __git_has_doubledash && return;
    local cur="${COMP_WORDS[COMP_CWORD]}";
    case "$cur" in 
        --*)
            __gitcomp "--dry-run --quiet";
            return
        ;;
    esac;
    COMPREPLY=()
}
_git_clone () 
{ 
    local cur="${COMP_WORDS[COMP_CWORD]}";
    case "$cur" in 
        --*)
            __gitcomp "
			--local
			--no-hardlinks
			--shared
			--reference
			--quiet
			--no-checkout
			--bare
			--mirror
			--origin
			--upload-pack
			--template=
			--depth
			";
            return
        ;;
    esac;
    COMPREPLY=()
}
_git_commit () 
{ 
    __git_has_doubledash && return;
    local cur="${COMP_WORDS[COMP_CWORD]}";
    case "$cur" in 
        --cleanup=*)
            __gitcomp "default strip verbatim whitespace
			" "" "${cur##--cleanup=}";
            return
        ;;
        --reuse-message=*)
            __gitcomp "$(__git_refs)" "" "${cur##--reuse-message=}";
            return
        ;;
        --reedit-message=*)
            __gitcomp "$(__git_refs)" "" "${cur##--reedit-message=}";
            return
        ;;
        --untracked-files=*)
            __gitcomp "all no normal" "" "${cur##--untracked-files=}";
            return
        ;;
        --*)
            __gitcomp "
			--all --author= --signoff --verify --no-verify
			--edit --amend --include --only --interactive
			--dry-run --reuse-message= --reedit-message=
			--reset-author --file= --message= --template=
			--cleanup= --untracked-files --untracked-files=
			--verbose --quiet
			";
            return
        ;;
    esac;
    COMPREPLY=()
}
_git_config () 
{ 
    local cur="${COMP_WORDS[COMP_CWORD]}";
    local prv="${COMP_WORDS[COMP_CWORD-1]}";
    case "$prv" in 
        branch.*.remote)
            __gitcomp "$(__git_remotes)";
            return
        ;;
        branch.*.merge)
            __gitcomp "$(__git_refs)";
            return
        ;;
        remote.*.fetch)
            local remote="${prv#remote.}";
            remote="${remote%.fetch}";
            __gitcomp "$(__git_refs_remotes "$remote")";
            return
        ;;
        remote.*.push)
            local remote="${prv#remote.}";
            remote="${remote%.push}";
            __gitcomp "$(git --git-dir="$(__gitdir)" 			for-each-ref --format='%(refname):%(refname)' 			refs/heads)";
            return
        ;;
        pull.twohead | pull.octopus)
            __git_compute_merge_strategies;
            __gitcomp "$__git_merge_strategies";
            return
        ;;
        color.branch | color.diff | color.interactive | color.showbranch | color.status | color.ui)
            __gitcomp "always never auto";
            return
        ;;
        color.pager)
            __gitcomp "false true";
            return
        ;;
        color.*.*)
            __gitcomp "
			normal black red green yellow blue magenta cyan white
			bold dim ul blink reverse
			";
            return
        ;;
        help.format)
            __gitcomp "man info web html";
            return
        ;;
        log.date)
            __gitcomp "$__git_log_date_formats";
            return
        ;;
        sendemail.aliasesfiletype)
            __gitcomp "mutt mailrc pine elm gnus";
            return
        ;;
        sendemail.confirm)
            __gitcomp "$__git_send_email_confirm_options";
            return
        ;;
        sendemail.suppresscc)
            __gitcomp "$__git_send_email_suppresscc_options";
            return
        ;;
        --get | --get-all | --unset | --unset-all)
            __gitcomp "$(__git_config_get_set_variables)";
            return
        ;;
        *.*)
            COMPREPLY=();
            return
        ;;
    esac;
    case "$cur" in 
        --*)
            __gitcomp "
			--global --system --file=
			--list --replace-all
			--get --get-all --get-regexp
			--add --unset --unset-all
			--remove-section --rename-section
			";
            return
        ;;
        branch.*.*)
            local pfx="${cur%.*}.";
            cur="${cur##*.}";
            __gitcomp "remote merge mergeoptions rebase" "$pfx" "$cur";
            return
        ;;
        branch.*)
            local pfx="${cur%.*}.";
            cur="${cur#*.}";
            __gitcomp "$(__git_heads)" "$pfx" "$cur" ".";
            return
        ;;
        guitool.*.*)
            local pfx="${cur%.*}.";
            cur="${cur##*.}";
            __gitcomp "
			argprompt cmd confirm needsfile noconsole norescan
			prompt revprompt revunmerged title
			" "$pfx" "$cur";
            return
        ;;
        difftool.*.*)
            local pfx="${cur%.*}.";
            cur="${cur##*.}";
            __gitcomp "cmd path" "$pfx" "$cur";
            return
        ;;
        man.*.*)
            local pfx="${cur%.*}.";
            cur="${cur##*.}";
            __gitcomp "cmd path" "$pfx" "$cur";
            return
        ;;
        mergetool.*.*)
            local pfx="${cur%.*}.";
            cur="${cur##*.}";
            __gitcomp "cmd path trustExitCode" "$pfx" "$cur";
            return
        ;;
        pager.*)
            local pfx="${cur%.*}.";
            cur="${cur#*.}";
            __git_compute_all_commands;
            __gitcomp "$__git_all_commands" "$pfx" "$cur";
            return
        ;;
        remote.*.*)
            local pfx="${cur%.*}.";
            cur="${cur##*.}";
            __gitcomp "
			url proxy fetch push mirror skipDefaultUpdate
			receivepack uploadpack tagopt pushurl
			" "$pfx" "$cur";
            return
        ;;
        remote.*)
            local pfx="${cur%.*}.";
            cur="${cur#*.}";
            __gitcomp "$(__git_remotes)" "$pfx" "$cur" ".";
            return
        ;;
        url.*.*)
            local pfx="${cur%.*}.";
            cur="${cur##*.}";
            __gitcomp "insteadOf pushInsteadOf" "$pfx" "$cur";
            return
        ;;
    esac;
    __gitcomp "
		add.ignore-errors
		alias.
		apply.ignorewhitespace
		apply.whitespace
		branch.autosetupmerge
		branch.autosetuprebase
		clean.requireForce
		color.branch
		color.branch.current
		color.branch.local
		color.branch.plain
		color.branch.remote
		color.diff
		color.diff.commit
		color.diff.frag
		color.diff.meta
		color.diff.new
		color.diff.old
		color.diff.plain
		color.diff.whitespace
		color.grep
		color.grep.external
		color.grep.match
		color.interactive
		color.interactive.header
		color.interactive.help
		color.interactive.prompt
		color.pager
		color.showbranch
		color.status
		color.status.added
		color.status.changed
		color.status.header
		color.status.nobranch
		color.status.untracked
		color.status.updated
		color.ui
		commit.template
		core.autocrlf
		core.bare
		core.compression
		core.createObject
		core.deltaBaseCacheLimit
		core.editor
		core.excludesfile
		core.fileMode
		core.fsyncobjectfiles
		core.gitProxy
		core.ignoreCygwinFSTricks
		core.ignoreStat
		core.logAllRefUpdates
		core.loosecompression
		core.packedGitLimit
		core.packedGitWindowSize
		core.pager
		core.preferSymlinkRefs
		core.preloadindex
		core.quotepath
		core.repositoryFormatVersion
		core.safecrlf
		core.sharedRepository
		core.symlinks
		core.trustctime
		core.warnAmbiguousRefs
		core.whitespace
		core.worktree
		diff.autorefreshindex
		diff.external
		diff.mnemonicprefix
		diff.renameLimit
		diff.renameLimit.
		diff.renames
		diff.suppressBlankEmpty
		diff.tool
		diff.wordRegex
		difftool.
		difftool.prompt
		fetch.unpackLimit
		format.attach
		format.cc
		format.headers
		format.numbered
		format.pretty
		format.signoff
		format.subjectprefix
		format.suffix
		format.thread
		gc.aggressiveWindow
		gc.auto
		gc.autopacklimit
		gc.packrefs
		gc.pruneexpire
		gc.reflogexpire
		gc.reflogexpireunreachable
		gc.rerereresolved
		gc.rerereunresolved
		gitcvs.allbinary
		gitcvs.commitmsgannotation
		gitcvs.dbTableNamePrefix
		gitcvs.dbdriver
		gitcvs.dbname
		gitcvs.dbpass
		gitcvs.dbuser
		gitcvs.enabled
		gitcvs.logfile
		gitcvs.usecrlfattr
		guitool.
		gui.blamehistoryctx
		gui.commitmsgwidth
		gui.copyblamethreshold
		gui.diffcontext
		gui.encoding
		gui.fastcopyblame
		gui.matchtrackingbranch
		gui.newbranchtemplate
		gui.pruneduringfetch
		gui.spellingdictionary
		gui.trustmtime
		help.autocorrect
		help.browser
		help.format
		http.lowSpeedLimit
		http.lowSpeedTime
		http.maxRequests
		http.noEPSV
		http.proxy
		http.sslCAInfo
		http.sslCAPath
		http.sslCert
		http.sslKey
		http.sslVerify
		i18n.commitEncoding
		i18n.logOutputEncoding
		imap.folder
		imap.host
		imap.pass
		imap.port
		imap.preformattedHTML
		imap.sslverify
		imap.tunnel
		imap.user
		instaweb.browser
		instaweb.httpd
		instaweb.local
		instaweb.modulepath
		instaweb.port
		interactive.singlekey
		log.date
		log.showroot
		mailmap.file
		man.
		man.viewer
		merge.conflictstyle
		merge.log
		merge.renameLimit
		merge.stat
		merge.tool
		merge.verbosity
		mergetool.
		mergetool.keepBackup
		mergetool.prompt
		pack.compression
		pack.deltaCacheLimit
		pack.deltaCacheSize
		pack.depth
		pack.indexVersion
		pack.packSizeLimit
		pack.threads
		pack.window
		pack.windowMemory
		pager.
		pull.octopus
		pull.twohead
		push.default
		rebase.stat
		receive.denyCurrentBranch
		receive.denyDeletes
		receive.denyNonFastForwards
		receive.fsckObjects
		receive.unpackLimit
		repack.usedeltabaseoffset
		rerere.autoupdate
		rerere.enabled
		sendemail.aliasesfile
		sendemail.aliasesfiletype
		sendemail.bcc
		sendemail.cc
		sendemail.cccmd
		sendemail.chainreplyto
		sendemail.confirm
		sendemail.envelopesender
		sendemail.multiedit
		sendemail.signedoffbycc
		sendemail.smtpencryption
		sendemail.smtppass
		sendemail.smtpserver
		sendemail.smtpserverport
		sendemail.smtpuser
		sendemail.suppresscc
		sendemail.suppressfrom
		sendemail.thread
		sendemail.to
		sendemail.validate
		showbranch.default
		status.relativePaths
		status.showUntrackedFiles
		tar.umask
		transfer.unpackLimit
		url.
		user.email
		user.name
		user.signingkey
		web.browser
		branch. remote.
	"
}
_git_describe () 
{ 
    local cur="${COMP_WORDS[COMP_CWORD]}";
    case "$cur" in 
        --*)
            __gitcomp "
			--all --tags --contains --abbrev= --candidates=
			--exact-match --debug --long --match --always
			";
            return
        ;;
    esac;
    __gitcomp "$(__git_refs)"
}
_git_diff () 
{ 
    __git_has_doubledash && return;
    local cur="${COMP_WORDS[COMP_CWORD]}";
    case "$cur" in 
        --*)
            __gitcomp "--cached --staged --pickaxe-all --pickaxe-regex
			--base --ours --theirs
			$__git_diff_common_options
			";
            return
        ;;
    esac;
    __git_complete_file
}
_git_difftool () 
{ 
    __git_has_doubledash && return;
    local cur="${COMP_WORDS[COMP_CWORD]}";
    case "$cur" in 
        --tool=*)
            __gitcomp "$__git_mergetools_common kompare" "" "${cur##--tool=}";
            return
        ;;
        --*)
            __gitcomp "--cached --staged --pickaxe-all --pickaxe-regex
			--base --ours --theirs
			--no-renames --diff-filter= --find-copies-harder
			--relative --ignore-submodules
			--tool=";
            return
        ;;
    esac;
    __git_complete_file
}
_git_fetch () 
{ 
    local cur="${COMP_WORDS[COMP_CWORD]}";
    case "$cur" in 
        --*)
            __gitcomp "$__git_fetch_options";
            return
        ;;
    esac;
    __git_complete_remote_or_refspec
}
_git_format_patch () 
{ 
    local cur="${COMP_WORDS[COMP_CWORD]}";
    case "$cur" in 
        --thread=*)
            __gitcomp "
			deep shallow
			" "" "${cur##--thread=}";
            return
        ;;
        --*)
            __gitcomp "
			--stdout --attach --no-attach --thread --thread=
			--output-directory
			--numbered --start-number
			--numbered-files
			--keep-subject
			--signoff
			--in-reply-to= --cc=
			--full-index --binary
			--not --all
			--cover-letter
			--no-prefix --src-prefix= --dst-prefix=
			--inline --suffix= --ignore-if-in-upstream
			--subject-prefix=
			";
            return
        ;;
    esac;
    __git_complete_revlist
}
_git_fsck () 
{ 
    local cur="${COMP_WORDS[COMP_CWORD]}";
    case "$cur" in 
        --*)
            __gitcomp "
			--tags --root --unreachable --cache --no-reflogs --full
			--strict --verbose --lost-found
			";
            return
        ;;
    esac;
    COMPREPLY=()
}
_git_gc () 
{ 
    local cur="${COMP_WORDS[COMP_CWORD]}";
    case "$cur" in 
        --*)
            __gitcomp "--prune --aggressive";
            return
        ;;
    esac;
    COMPREPLY=()
}
_git_grep () 
{ 
    __git_has_doubledash && return;
    local cur="${COMP_WORDS[COMP_CWORD]}";
    case "$cur" in 
        --*)
            __gitcomp "
			--cached
			--text --ignore-case --word-regexp --invert-match
			--full-name
			--extended-regexp --basic-regexp --fixed-strings
			--files-with-matches --name-only
			--files-without-match
			--max-depth
			--count
			--and --or --not --all-match
			";
            return
        ;;
    esac;
    __gitcomp "$(__git_refs)"
}
_git_help () 
{ 
    local cur="${COMP_WORDS[COMP_CWORD]}";
    case "$cur" in 
        --*)
            __gitcomp "--all --info --man --web";
            return
        ;;
    esac;
    __git_compute_all_commands;
    __gitcomp "$__git_all_commands
		attributes cli core-tutorial cvs-migration
		diffcore gitk glossary hooks ignore modules
		repository-layout tutorial tutorial-2
		workflows
		"
}
_git_init () 
{ 
    local cur="${COMP_WORDS[COMP_CWORD]}";
    case "$cur" in 
        --shared=*)
            __gitcomp "
			false true umask group all world everybody
			" "" "${cur##--shared=}";
            return
        ;;
        --*)
            __gitcomp "--quiet --bare --template= --shared --shared=";
            return
        ;;
    esac;
    COMPREPLY=()
}
_git_log () 
{ 
    __git_has_doubledash && return;
    local cur="${COMP_WORDS[COMP_CWORD]}";
    local g="$(git rev-parse --git-dir 2>/dev/null)";
    local merge="";
    if [ -f "$g/MERGE_HEAD" ]; then
        merge="--merge";
    fi;
    case "$cur" in 
        --pretty=*)
            __gitcomp "$__git_log_pretty_formats
			" "" "${cur##--pretty=}";
            return
        ;;
        --format=*)
            __gitcomp "$__git_log_pretty_formats
			" "" "${cur##--format=}";
            return
        ;;
        --date=*)
            __gitcomp "$__git_log_date_formats" "" "${cur##--date=}";
            return
        ;;
        --decorate=*)
            __gitcomp "long short" "" "${cur##--decorate=}";
            return
        ;;
        --*)
            __gitcomp "
			$__git_log_common_options
			$__git_log_shortlog_options
			$__git_log_gitk_options
			--root --topo-order --date-order --reverse
			--follow --full-diff
			--abbrev-commit --abbrev=
			--relative-date --date=
			--pretty= --format= --oneline
			--cherry-pick
			--graph
			--decorate --decorate=
			--walk-reflogs
			--parents --children
			$merge
			$__git_diff_common_options
			--pickaxe-all --pickaxe-regex
			";
            return
        ;;
    esac;
    __git_complete_revlist
}
_git_ls_files () 
{ 
    __git_has_doubledash && return;
    local cur="${COMP_WORDS[COMP_CWORD]}";
    case "$cur" in 
        --*)
            __gitcomp "--cached --deleted --modified --others --ignored
			--stage --directory --no-empty-directory --unmerged
			--killed --exclude= --exclude-from=
			--exclude-per-directory= --exclude-standard
			--error-unmatch --with-tree= --full-name
			--abbrev --ignored --exclude-per-directory
			";
            return
        ;;
    esac;
    COMPREPLY=()
}
_git_ls_remote () 
{ 
    __gitcomp "$(__git_remotes)"
}
_git_ls_tree () 
{ 
    __git_complete_file
}
_git_merge () 
{ 
    __git_complete_strategy && return;
    local cur="${COMP_WORDS[COMP_CWORD]}";
    case "$cur" in 
        --*)
            __gitcomp "$__git_merge_options";
            return
        ;;
    esac;
    __gitcomp "$(__git_refs)"
}
_git_merge_base () 
{ 
    __gitcomp "$(__git_refs)"
}
_git_mergetool () 
{ 
    local cur="${COMP_WORDS[COMP_CWORD]}";
    case "$cur" in 
        --tool=*)
            __gitcomp "$__git_mergetools_common tortoisemerge" "" "${cur##--tool=}";
            return
        ;;
        --*)
            __gitcomp "--tool=";
            return
        ;;
    esac;
    COMPREPLY=()
}
_git_mv () 
{ 
    local cur="${COMP_WORDS[COMP_CWORD]}";
    case "$cur" in 
        --*)
            __gitcomp "--dry-run";
            return
        ;;
    esac;
    COMPREPLY=()
}
_git_name_rev () 
{ 
    __gitcomp "--tags --all --stdin"
}
_git_notes () 
{ 
    local subcommands="edit show";
    if [ -z "$(__git_find_on_cmdline "$subcommands")" ]; then
        __gitcomp "$subcommands";
        return;
    fi;
    case "${COMP_WORDS[COMP_CWORD-1]}" in 
        -m | -F)
            COMPREPLY=()
        ;;
        *)
            __gitcomp "$(__git_refs)"
        ;;
    esac
}
_git_pull () 
{ 
    __git_complete_strategy && return;
    local cur="${COMP_WORDS[COMP_CWORD]}";
    case "$cur" in 
        --*)
            __gitcomp "
			--rebase --no-rebase
			$__git_merge_options
			$__git_fetch_options
		";
            return
        ;;
    esac;
    __git_complete_remote_or_refspec
}
_git_push () 
{ 
    local cur="${COMP_WORDS[COMP_CWORD]}";
    case "${COMP_WORDS[COMP_CWORD-1]}" in 
        --repo)
            __gitcomp "$(__git_remotes)";
            return
        ;;
    esac;
    case "$cur" in 
        --repo=*)
            __gitcomp "$(__git_remotes)" "" "${cur##--repo=}";
            return
        ;;
        --*)
            __gitcomp "
			--all --mirror --tags --dry-run --force --verbose
			--receive-pack= --repo=
		";
            return
        ;;
    esac;
    __git_complete_remote_or_refspec
}
_git_rebase () 
{ 
    local cur="${COMP_WORDS[COMP_CWORD]}" dir="$(__gitdir)";
    if [ -d "$dir"/rebase-apply ] || [ -d "$dir"/rebase-merge ]; then
        __gitcomp "--continue --skip --abort";
        return;
    fi;
    __git_complete_strategy && return;
    case "$cur" in 
        --whitespace=*)
            __gitcomp "$__git_whitespacelist" "" "${cur##--whitespace=}";
            return
        ;;
        --*)
            __gitcomp "
			--onto --merge --strategy --interactive
			--preserve-merges --stat --no-stat
			--committer-date-is-author-date --ignore-date
			--ignore-whitespace --whitespace=
			--autosquash
			";
            return
        ;;
    esac;
    __gitcomp "$(__git_refs)"
}
_git_remote () 
{ 
    local subcommands="add rename rm show prune update set-head";
    local subcommand="$(__git_find_on_cmdline "$subcommands")";
    if [ -z "$subcommand" ]; then
        __gitcomp "$subcommands";
        return;
    fi;
    case "$subcommand" in 
        rename | rm | show | prune)
            __gitcomp "$(__git_remotes)"
        ;;
        update)
            local i c='' IFS='
';
            for i in $(git --git-dir="$(__gitdir)" config --get-regexp "remotes\..*" 2>/dev/null);
            do
                i="${i#remotes.}";
                c="$c ${i/ */}";
            done;
            __gitcomp "$c"
        ;;
        *)
            COMPREPLY=()
        ;;
    esac
}
_git_replace () 
{ 
    __gitcomp "$(__git_refs)"
}
_git_reset () 
{ 
    __git_has_doubledash && return;
    local cur="${COMP_WORDS[COMP_CWORD]}";
    case "$cur" in 
        --*)
            __gitcomp "--merge --mixed --hard --soft --patch";
            return
        ;;
    esac;
    __gitcomp "$(__git_refs)"
}
_git_revert () 
{ 
    local cur="${COMP_WORDS[COMP_CWORD]}";
    case "$cur" in 
        --*)
            __gitcomp "--edit --mainline --no-edit --no-commit --signoff";
            return
        ;;
    esac;
    __gitcomp "$(__git_refs)"
}
_git_rm () 
{ 
    __git_has_doubledash && return;
    local cur="${COMP_WORDS[COMP_CWORD]}";
    case "$cur" in 
        --*)
            __gitcomp "--cached --dry-run --ignore-unmatch --quiet";
            return
        ;;
    esac;
    COMPREPLY=()
}
_git_send_email () 
{ 
    local cur="${COMP_WORDS[COMP_CWORD]}";
    case "$cur" in 
        --confirm=*)
            __gitcomp "
			$__git_send_email_confirm_options
			" "" "${cur##--confirm=}";
            return
        ;;
        --suppress-cc=*)
            __gitcomp "
			$__git_send_email_suppresscc_options
			" "" "${cur##--suppress-cc=}";
            return
        ;;
        --smtp-encryption=*)
            __gitcomp "ssl tls" "" "${cur##--smtp-encryption=}";
            return
        ;;
        --*)
            __gitcomp "--annotate --bcc --cc --cc-cmd --chain-reply-to
			--compose --confirm= --dry-run --envelope-sender
			--from --identity
			--in-reply-to --no-chain-reply-to --no-signed-off-by-cc
			--no-suppress-from --no-thread --quiet
			--signed-off-by-cc --smtp-pass --smtp-server
			--smtp-server-port --smtp-encryption= --smtp-user
			--subject --suppress-cc= --suppress-from --thread --to
			--validate --no-validate";
            return
        ;;
    esac;
    COMPREPLY=()
}
_git_shortlog () 
{ 
    __git_has_doubledash && return;
    local cur="${COMP_WORDS[COMP_CWORD]}";
    case "$cur" in 
        --*)
            __gitcomp "
			$__git_log_common_options
			$__git_log_shortlog_options
			--numbered --summary
			";
            return
        ;;
    esac;
    __git_complete_revlist
}
_git_show () 
{ 
    __git_has_doubledash && return;
    local cur="${COMP_WORDS[COMP_CWORD]}";
    case "$cur" in 
        --pretty=*)
            __gitcomp "$__git_log_pretty_formats
			" "" "${cur##--pretty=}";
            return
        ;;
        --format=*)
            __gitcomp "$__git_log_pretty_formats
			" "" "${cur##--format=}";
            return
        ;;
        --*)
            __gitcomp "--pretty= --format= --abbrev-commit --oneline
			$__git_diff_common_options
			";
            return
        ;;
    esac;
    __git_complete_file
}
_git_show_branch () 
{ 
    local cur="${COMP_WORDS[COMP_CWORD]}";
    case "$cur" in 
        --*)
            __gitcomp "
			--all --remotes --topo-order --current --more=
			--list --independent --merge-base --no-name
			--color --no-color
			--sha1-name --sparse --topics --reflog
			";
            return
        ;;
    esac;
    __git_complete_revlist
}
_git_stash () 
{ 
    local cur="${COMP_WORDS[COMP_CWORD]}";
    local save_opts='--keep-index --no-keep-index --quiet --patch';
    local subcommands='save list show apply clear drop pop create branch';
    local subcommand="$(__git_find_on_cmdline "$subcommands")";
    if [ -z "$subcommand" ]; then
        case "$cur" in 
            --*)
                __gitcomp "$save_opts"
            ;;
            *)
                if [ -z "$(__git_find_on_cmdline "$save_opts")" ]; then
                    __gitcomp "$subcommands";
                else
                    COMPREPLY=();
                fi
            ;;
        esac;
    else
        case "$subcommand,$cur" in 
            save,--*)
                __gitcomp "$save_opts"
            ;;
            apply,--* | pop,--*)
                __gitcomp "--index --quiet"
            ;;
            show,--* | drop,--* | branch,--*)
                COMPREPLY=()
            ;;
            show,* | apply,* | drop,* | pop,* | branch,*)
                __gitcomp "$(git --git-dir="$(__gitdir)" stash list 					| sed -n -e 's/:.*//p')"
            ;;
            *)
                COMPREPLY=()
            ;;
        esac;
    fi
}
_git_submodule () 
{ 
    __git_has_doubledash && return;
    local subcommands="add status init update summary foreach sync";
    if [ -z "$(__git_find_on_cmdline "$subcommands")" ]; then
        local cur="${COMP_WORDS[COMP_CWORD]}";
        case "$cur" in 
            --*)
                __gitcomp "--quiet --cached"
            ;;
            *)
                __gitcomp "$subcommands"
            ;;
        esac;
        return;
    fi
}
_git_svn () 
{ 
    local subcommands="
		init fetch clone rebase dcommit log find-rev
		set-tree commit-diff info create-ignore propget
		proplist show-ignore show-externals branch tag blame
		migrate mkdirs reset gc
		";
    local subcommand="$(__git_find_on_cmdline "$subcommands")";
    if [ -z "$subcommand" ]; then
        __gitcomp "$subcommands";
    else
        local remote_opts="--username= --config-dir= --no-auth-cache";
        local fc_opts="
			--follow-parent --authors-file= --repack=
			--no-metadata --use-svm-props --use-svnsync-props
			--log-window-size= --no-checkout --quiet
			--repack-flags --use-log-author --localtime
			--ignore-paths= $remote_opts
			";
        local init_opts="
			--template= --shared= --trunk= --tags=
			--branches= --stdlayout --minimize-url
			--no-metadata --use-svm-props --use-svnsync-props
			--rewrite-root= --prefix= --use-log-author
			--add-author-from $remote_opts
			";
        local cmt_opts="
			--edit --rmdir --find-copies-harder --copy-similarity=
			";
        local cur="${COMP_WORDS[COMP_CWORD]}";
        case "$subcommand,$cur" in 
            fetch,--*)
                __gitcomp "--revision= --fetch-all $fc_opts"
            ;;
            clone,--*)
                __gitcomp "--revision= $fc_opts $init_opts"
            ;;
            init,--*)
                __gitcomp "$init_opts"
            ;;
            dcommit,--*)
                __gitcomp "
				--merge --strategy= --verbose --dry-run
				--fetch-all --no-rebase --commit-url
				--revision $cmt_opts $fc_opts
				"
            ;;
            set-tree,--*)
                __gitcomp "--stdin $cmt_opts $fc_opts"
            ;;
            create-ignore,--* | propget,--* | proplist,--* | show-ignore,--* | show-externals,--* | mkdirs,--*)
                __gitcomp "--revision="
            ;;
            log,--*)
                __gitcomp "
				--limit= --revision= --verbose --incremental
				--oneline --show-commit --non-recursive
				--authors-file= --color
				"
            ;;
            rebase,--*)
                __gitcomp "
				--merge --verbose --strategy= --local
				--fetch-all --dry-run $fc_opts
				"
            ;;
            commit-diff,--*)
                __gitcomp "--message= --file= --revision= $cmt_opts"
            ;;
            info,--*)
                __gitcomp "--url"
            ;;
            branch,--*)
                __gitcomp "--dry-run --message --tag"
            ;;
            tag,--*)
                __gitcomp "--dry-run --message"
            ;;
            blame,--*)
                __gitcomp "--git-format"
            ;;
            migrate,--*)
                __gitcomp "
				--config-dir= --ignore-paths= --minimize
				--no-auth-cache --username=
				"
            ;;
            reset,--*)
                __gitcomp "--revision= --parent"
            ;;
            *)
                COMPREPLY=()
            ;;
        esac;
    fi
}
_git_tag () 
{ 
    local i c=1 f=0;
    while [ $c -lt $COMP_CWORD ]; do
        i="${COMP_WORDS[c]}";
        case "$i" in 
            -d | -v)
                __gitcomp "$(__git_tags)";
                return
            ;;
            -f)
                f=1
            ;;
        esac;
        c=$((++c));
    done;
    case "${COMP_WORDS[COMP_CWORD-1]}" in 
        -m | -F)
            COMPREPLY=()
        ;;
        -* | tag)
            if [ $f = 1 ]; then
                __gitcomp "$(__git_tags)";
            else
                COMPREPLY=();
            fi
        ;;
        *)
            __gitcomp "$(__git_refs)"
        ;;
    esac
}
_gitk () 
{ 
    __git_has_doubledash && return;
    local cur="${COMP_WORDS[COMP_CWORD]}";
    local g="$(__gitdir)";
    local merge="";
    if [ -f "$g/MERGE_HEAD" ]; then
        merge="--merge";
    fi;
    case "$cur" in 
        --*)
            __gitcomp "
			$__git_log_common_options
			$__git_log_gitk_options
			$merge
			";
            return
        ;;
    esac;
    __git_complete_revlist
}
_gpasswd () 
{ 
    local cur prev;
    COMPREPLY=();
    cur=`_get_cword`;
    prev=${COMP_WORDS[COMP_CWORD-1]};
    case "$prev" in 
        -a | -d | -A | -M)
            COMPREPLY=($( compgen -u -- "$cur" ));
            return 0
        ;;
    esac;
    if [[ "$cur" == -* ]]; then
        COMPREPLY=($( compgen -W '-a -d -r -R -A -M' -- "$cur" ));
        return 0;
    fi;
    [ -n "$bash205" ] && COMPREPLY=($( compgen -g -- "$cur" ))
}
_gpg () 
{ 
    local cur prev;
    COMPREPLY=();
    cur=`_get_cword`;
    prev=${COMP_WORDS[COMP_CWORD-1]};
    case "$prev" in 
        -@(s|-sign|-clearsign|-decrypt-files|-load-extension))
            _filedir;
            return 0
        ;;
        --@(export|@(?(l|nr|nrl)sign|edit)-key))
            COMPREPLY=($( compgen -W "$( gpg --list-keys 2>/dev/null |                 sed -ne 's@^pub.*/\([^ ]*\).*$@\1@p;s@^.*\(<\([^>]*\)>\).*$@\2@p')" -- "$cur" ));
            return 0
        ;;
        -@(r|-recipient))
            COMPREPLY=($( compgen -W "$( gpg --list-keys 2>/dev/null |                 sed -ne 's@^.*<\([^>]*\)>.*$@\1@p')" -- "$cur" ));
            if [ -e ~/.gnupg/gpg.conf ]; then
                COMPREPLY=("${COMPREPLY[@]}" $( compgen -W "$( sed -ne                     's@^[ \t]*group[ \t][ \t]*\([^=]*\).*$@\1@p'                     ~/.gnupg/gpg.conf  )" -- "$cur"));
            fi;
            return 0
        ;;
    esac;
    if [[ "$cur" == -* ]]; then
        COMPREPLY=($( compgen -W '-s -b -e -f -c -d -a -r -u -Z -o -v\
            -q -n -N $(gpg --dump-options)' -- "$cur" ));
    fi
}
_groupadd () 
{ 
    local cur prev split=false;
    COMPREPLY=();
    cur=`_get_cword`;
    prev=${COMP_WORDS[COMP_CWORD-1]};
    _split_longopt && split=true;
    case "$prev" in 
        -g | --gid | -K | --key | -p | --password)
            return 0
        ;;
    esac;
    $split && return 0;
    if [[ "$cur" == -* ]]; then
        COMPREPLY=($( compgen -W '-f --force -g --gid -h --help \
            -K --key -o --non-unique -p --password -r --system'             -- "$cur" ));
        return 0;
    fi
}
_groupmod () 
{ 
    local cur prev split=false;
    COMPREPLY=();
    cur=`_get_cword`;
    prev=${COMP_WORDS[COMP_CWORD-1]};
    _split_longopt && split=true;
    case "$prev" in 
        -g | --gid | -h | --help | -n | --new-name | -p | --password)
            return 0
        ;;
    esac;
    $split && return 0;
    if [[ "$cur" == -* ]]; then
        COMPREPLY=($( compgen -W '-g --gid -h --help -n --new-name \
            -o --non-unique -p --password' -- "$cur" ));
        return 0;
    fi;
    [ -n "$bash205" ] && COMPREPLY=($( compgen -g -- "$cur" ))
}
_grpck () 
{ 
    local cur;
    COMPREPLY=();
    cur=`_get_cword`;
    if [[ "$cur" == -* ]]; then
        COMPREPLY=($( compgen -W '-r -s' -- "$cur" ));
        return 0;
    fi;
    _filedir
}
_gzip () 
{ 
    local cur prev xspec helpopts;
    COMPREPLY=();
    cur=`_get_cword`;
    prev=${COMP_WORDS[COMP_CWORD-1]};
    helpopts=`_parse_help gzip`;
    if [[ "$cur" == -* ]]; then
        COMPREPLY=($( compgen -W "$helpopts -2 -3 -4 -5 -6 -7 -8" -- "$cur" ));
        return 0;
    fi;
    local IFS='	
';
    xspec="*.?(t)gz";
    if [[ "$prev" == --* ]]; then
        [[ "$prev" == --decompress || "$prev" == --list || "$prev" == --test ]] && xspec="!"$xspec;
        [[ "$prev" == --force ]] && xspec=;
    else
        if [[ "$prev" == -* ]]; then
            [[ "$prev" == -*[dlt]* ]] && xspec="!"$xspec;
            [[ "$prev" == -*f* ]] && xspec=;
        else
            if [ "$prev" = '>' -o "$prev" = '>>' ]; then
                xspec=;
            else
                if [ "$prev" = '<' ]; then
                    xspec=;
                fi;
            fi;
        fi;
    fi;
    _expand || return 0;
    COMPREPLY=($( compgen -f -X "$xspec" -- "$cur" ) $( compgen -d -- "$cur" ))
}
_hciattach () 
{ 
    local cur;
    COMPREPLY=();
    cur=`_get_cword`;
    if [[ "$cur" == -* ]]; then
        COMPREPLY=($( compgen -W '-n -p -t -b -s -l' -- "$cur" ));
    else
        _count_args;
        case $args in 
            1)
                COMPREPLY=($( command ls /dev/tty* ));
                COMPREPLY=($( compgen -W '${COMPREPLY[@]} \
                    ${COMPREPLY[@]#/dev/}' -- "$cur" ))
            ;;
            2)
                COMPREPLY=($( compgen -W 'any ericsson digi \
                    xircom csr bboxes swave bcsp 0x0105 \
                    0x080a 0x0160 0x0002' -- "$cur" ))
            ;;
            3)
                COMPREPLY=($( compgen -W '9600 19200 38400 \
                    57600 115200 230400 460800 921600' -- "$cur" ))
            ;;
            4)
                COMPREPLY=($( compgen -W 'flow noflow' -- "$cur" ))
            ;;
            5)
                _bluetooth_adresses
            ;;
        esac;
    fi
}
_hciconfig () 
{ 
    local cur;
    COMPREPLY=();
    cur=`_get_cword`;
    _get_command;
    if [ -z $command ]; then
        if [[ "$cur" == -* ]]; then
            COMPREPLY=($( compgen -W '-h --help -a --all' -- "$cur" ));
        else
            COMPREPLY=($( compgen -W 'up down reset rstat auth \
                noauth encrypt noencrypt secmgr nosecmgr \
                piscan noscan iscan pscan ptype name class \
                voice iac inqmode inqdata inqtype inqparams \
                pageparms pageto afhmode aclmtu scomtu putkey \
                delkey commands features version revision lm'                 -- "$cur" ));
        fi;
    else
        case $command in 
            @(putkey|delkey))
                _count_args;
                if [ $args -eq 2 ]; then
                    _bluetooth_adresses;
                fi
            ;;
            lm)
                _count_args;
                if [ $args -eq 2 ]; then
                    COMPREPLY=($( compgen -W 'MASTER \
                        SLAVE NONE ACCEPT' -- "$cur" ));
                fi
            ;;
            ptype)
                _count_args;
                if [ $args -eq 2 ]; then
                    _bluetooth_packet_types;
                fi
            ;;
        esac;
    fi
}
_hcitool () 
{ 
    local cur prev split=false;
    COMPREPLY=();
    cur=`_get_cword`;
    prev=${COMP_WORDS[COMP_CWORD-1]};
    _split_longopt && split=true;
    case $prev in 
        -i)
            _bluetooth_devices;
            return 0
        ;;
        --role)
            COMPREPLY=($( compgen -W 'm s' -- "$cur" ));
            return 0
        ;;
        --pkt-type)
            _bluetooth_packet_types;
            return 0
        ;;
    esac;
    $split && return 0;
    _get_command;
    if [ -z $command ]; then
        if [[ "$cur" == -* ]]; then
            COMPREPLY=($( compgen -W '-h -i' -- "$cur" ));
        else
            COMPREPLY=($( compgen -W 'dev inq scan name info \
                spinq epinq cmd con cc dc sr cpt rssi lq tpl \
                afh lst auth enc key clkoff clock' -- "$cur" ));
        fi;
    else
        case $command in 
            @(name|info|dc|rssi|lq|afh|auth|key|clkoff|lst))
                _count_args;
                if [ $args -eq 2 ]; then
                    _bluetooth_adresses;
                fi
            ;;
            cc)
                if [[ "$cur" == -* ]]; then
                    COMPREPLY=($( compgen -W '--role --pkt-type' -- "$cur" ));
                else
                    _count_args;
                    if [ $args -eq 2 ]; then
                        _bluetooth_adresses;
                    fi;
                fi
            ;;
            sr)
                _count_args;
                if [ $args -eq 2 ]; then
                    _bluetooth_adresses;
                else
                    COMPREPLY=($( compgen -W 'master slave' -- "$cur" ));
                fi
            ;;
            cpt)
                _count_args;
                if [ $args -eq 2 ]; then
                    _bluetooth_adresses;
                else
                    _bluetooth_packet_types;
                fi
            ;;
            @(tpl|enc|clock))
                _count_args;
                if [ $args -eq 2 ]; then
                    _bluetooth_adresses;
                else
                    COMPREPLY=($( compgen -W '0 1' -- "$cur" ));
                fi
            ;;
        esac;
    fi
}
_hg () 
{ 
    local cur prev cmd cmd_index opts i;
    local global_args='--cwd|-R|--repository';
    local hg="$1";
    local canonical=0;
    COMPREPLY=();
    cur="$2";
    prev="$3";
    for ((i=1; $i<=$COMP_CWORD; i++))
    do
        if [[ ${COMP_WORDS[i]} != -* ]]; then
            if [[ ${COMP_WORDS[i-1]} != @($global_args) ]]; then
                cmd="${COMP_WORDS[i]}";
                cmd_index=$i;
                break;
            fi;
        fi;
    done;
    if [[ "$cur" == -* ]]; then
        if [ "$(type -t "_hg_opt_$cmd")" = function ] && "_hg_opt_$cmd"; then
            return;
        fi;
        opts=$("$hg" debugcomplete --options "$cmd" 2>/dev/null);
        COMPREPLY=(${COMPREPLY[@]:-} $(compgen -W '$opts' -- "$cur"));
        return;
    fi;
    case "$prev" in 
        -R | --repository)
            _hg_paths;
            _hg_repos;
            return
        ;;
        --cwd)
            return
        ;;
    esac;
    if [ -z "$cmd" ] || [ $COMP_CWORD -eq $i ]; then
        _hg_commands;
        return;
    fi;
    local help;
    if _hg_command_specific; then
        return;
    fi;
    help=$("$hg" help "$cmd" 2>/dev/null);
    if [ $? -ne 0 ]; then
        return;
    fi;
    cmd=${help#hg };
    cmd=${cmd%%[' 
']*};
    canonical=1;
    _hg_command_specific
}
_hg_bookmarks () 
{ 
    local bookmarks="$("$hg" bookmarks --quiet 2>/dev/null )";
    local IFS='
';
    COMPREPLY=(${COMPREPLY[@]:-} $(compgen -W '$bookmarks' -- "$cur"))
}
_hg_branches () 
{ 
    local branches="$("$hg" branches -q 2>/dev/null)";
    local IFS='
';
    COMPREPLY=(${COMPREPLY[@]:-} $(compgen -W '$branches' -- "$cur"))
}
_hg_cmd_bisect () 
{ 
    local i subcmd;
    for ((i=cmd_index+1; i<=COMP_CWORD; i++))
    do
        if [[ ${COMP_WORDS[i]} != -* ]]; then
            if [[ ${COMP_WORDS[i-1]} != @($global_args) ]]; then
                subcmd="${COMP_WORDS[i]}";
                break;
            fi;
        fi;
    done;
    if [ -z "$subcmd" ] || [ $COMP_CWORD -eq $i ] || [ "$subcmd" = help ]; then
        COMPREPLY=(${COMPREPLY[@]:-} $(compgen -W 'bad good help init next reset' -- "$cur"));
        return;
    fi;
    case "$subcmd" in 
        good | bad)
            _hg_tags;
            _hg_branches
        ;;
    esac;
    return
}
_hg_cmd_bookmarks () 
{ 
    if [[ "$prev" = @(-d|--delete|-m|--rename) ]]; then
        _hg_bookmarks;
        return;
    fi
}
_hg_cmd_email () 
{ 
    case "$prev" in 
        -c | --cc | -t | --to | -f | --from | --bcc)
            if [ "$(type -t _hg_emails)" = function ]; then
                local arg=to;
                if [[ "$prev" == @(-f|--from) ]]; then
                    arg=from;
                fi;
                local addresses=$(_hg_emails $arg);
                COMPREPLY=(${COMPREPLY[@]:-} $(compgen -W '$addresses' -- "$cur"));
            fi;
            return
        ;;
        -m | --mbox)
            return
        ;;
        -s | --subject)
            return
        ;;
    esac;
    _hg_tags;
    _hg_branches;
    return
}
_hg_cmd_qclone () 
{ 
    local count=$(_hg_count_non_option);
    if [ $count = 1 ]; then
        _hg_paths;
    fi;
    _hg_repos
}
_hg_cmd_qcommit () 
{ 
    local root=$("$hg" root 2>/dev/null);
    local files=$(cd "$root/.hg/patches" 2>/dev/null &&
                  "$hg" status -nmar 2>/dev/null);
    COMPREPLY=(${COMPREPLY[@]:-} $(compgen -W '$files' -- "$cur"))
}
_hg_cmd_qdelete () 
{ 
    local qcmd=qunapplied;
    if [[ "$prev" = @(-r|--rev) ]]; then
        qcmd=qapplied;
    fi;
    _hg_ext_mq_patchlist $qcmd
}
_hg_cmd_qfinish () 
{ 
    if [[ "$prev" = @(-a|--applied) ]]; then
        return;
    fi;
    _hg_ext_mq_patchlist qapplied
}
_hg_cmd_qfold () 
{ 
    _hg_ext_mq_patchlist qunapplied
}
_hg_cmd_qgoto () 
{ 
    if [[ "$prev" = @(-n|--name) ]]; then
        _hg_ext_mq_queues;
        return;
    fi;
    _hg_ext_mq_patchlist qseries
}
_hg_cmd_qguard () 
{ 
    local prefix='';
    if [[ "$cur" == +* ]]; then
        prefix=+;
    else
        if [[ "$cur" == -* ]]; then
            prefix=-;
        fi;
    fi;
    local ncur=${cur#[-+]};
    if ! [ "$prefix" ]; then
        _hg_ext_mq_patchlist qseries;
        return;
    fi;
    local guards=$(_hg_ext_mq_guards);
    COMPREPLY=(${COMPREPLY[@]:-} $(compgen -P $prefix -W '$guards' -- "$ncur"))
}
_hg_cmd_qheader () 
{ 
    _hg_ext_mq_patchlist qseries
}
_hg_cmd_qpop () 
{ 
    if [[ "$prev" = @(-n|--name) ]]; then
        _hg_ext_mq_queues;
        return;
    fi;
    _hg_ext_mq_patchlist qapplied
}
_hg_cmd_qpush () 
{ 
    if [[ "$prev" = @(-n|--name) ]]; then
        _hg_ext_mq_queues;
        return;
    fi;
    _hg_ext_mq_patchlist qunapplied
}
_hg_cmd_qrename () 
{ 
    _hg_ext_mq_patchlist qseries
}
_hg_cmd_qsave () 
{ 
    if [[ "$prev" = @(-n|--name) ]]; then
        _hg_ext_mq_queues;
        return;
    fi
}
_hg_cmd_qselect () 
{ 
    local guards=$(_hg_ext_mq_guards);
    COMPREPLY=(${COMPREPLY[@]:-} $(compgen -W '$guards' -- "$cur"))
}
_hg_cmd_shelve () 
{ 
    _hg_status "mard"
}
_hg_cmd_sign () 
{ 
    _hg_tags;
    _hg_branches
}
_hg_cmd_strip () 
{ 
    _hg_tags;
    _hg_branches
}
_hg_cmd_transplant () 
{ 
    case "$prev" in 
        -s | --source)
            _hg_paths;
            _hg_repos;
            return
        ;;
        --filter)
            return
        ;;
    esac;
    _hg_tags;
    _hg_branches;
    return
}
_hg_cmd_unshelve () 
{ 
    _hg_shelves
}
_hg_command_specific () 
{ 
    if [ "$(type -t "_hg_cmd_$cmd")" = function ]; then
        "_hg_cmd_$cmd";
        return 0;
    fi;
    if [ "$cmd" != status ] && [ "$prev" = -r ] || [ "$prev" == --rev ]; then
        if [ $canonical = 1 ]; then
            _hg_tags;
            _hg_branches;
            return 0;
        else
            if [[ status != "$cmd"* ]]; then
                _hg_tags;
                _hg_branches;
                return 0;
            else
                return 1;
            fi;
        fi;
    fi;
    case "$cmd" in 
        help)
            _hg_commands
        ;;
        export)
            if _hg_ext_mq_patchlist qapplied && [ "${COMPREPLY[*]}" ]; then
                return 0;
            fi;
            _hg_tags;
            _hg_branches
        ;;
        manifest | update)
            _hg_tags;
            _hg_branches
        ;;
        pull | push | outgoing | incoming)
            _hg_paths;
            _hg_repos
        ;;
        paths)
            _hg_paths
        ;;
        add)
            _hg_status "u"
        ;;
        merge)
            _hg_tags;
            _hg_branches
        ;;
        commit)
            _hg_status "mar"
        ;;
        remove)
            _hg_status "d"
        ;;
        forget)
            _hg_status "a"
        ;;
        diff)
            _hg_status "mar"
        ;;
        revert)
            _hg_status "mard"
        ;;
        clone)
            local count=$(_hg_count_non_option);
            if [ $count = 1 ]; then
                _hg_paths;
            fi;
            _hg_repos
        ;;
        debugindex | debugindexdot)
            COMPREPLY=(${COMPREPLY[@]:-} $(compgen -f -X "!*.i" -- "$cur"))
        ;;
        debugdata)
            COMPREPLY=(${COMPREPLY[@]:-} $(compgen -f -X "!*.d" -- "$cur"))
        ;;
        *)
            return 1
        ;;
    esac;
    return 0
}
_hg_commands () 
{ 
    local commands;
    commands="$("$hg" debugcomplete "$cur" 2>/dev/null)" || commands="";
    COMPREPLY=(${COMPREPLY[@]:-} $(compgen -W '$commands' -- "$cur"))
}
_hg_count_non_option () 
{ 
    local i count=0;
    local filters="$1";
    for ((i=1; $i<=$COMP_CWORD; i++))
    do
        if [[ "${COMP_WORDS[i]}" != -* ]]; then
            if [[ ${COMP_WORDS[i-1]} == @($filters|$global_args) ]]; then
                continue;
            fi;
            count=$(($count + 1));
        fi;
    done;
    echo $(($count - 1))
}
_hg_ext_mq_guards () 
{ 
    "$hg" qselect --series 2> /dev/null | sed -e 's/^.//'
}
_hg_ext_mq_patchlist () 
{ 
    local patches;
    patches=$("$hg" $1 2>/dev/null);
    if [ $? -eq 0 ] && [ "$patches" ]; then
        COMPREPLY=(${COMPREPLY[@]:-} $(compgen -W '$patches' -- "$cur"));
        return 0;
    fi;
    return 1
}
_hg_ext_mq_queues () 
{ 
    local root=$("$hg" root 2>/dev/null);
    local n;
    for n in $(cd "$root"/.hg && compgen -d -- "$cur");
    do
        if [ "$n" != patches ] && [ -e "$root/.hg/$n/series" ]; then
            COMPREPLY=(${COMPREPLY[@]:-} "$n");
        fi;
    done
}
_hg_opt_qguard () 
{ 
    local i;
    for ((i=cmd_index+1; i<=COMP_CWORD; i++))
    do
        if [[ ${COMP_WORDS[i]} != -* ]]; then
            if [[ ${COMP_WORDS[i-1]} != @($global_args) ]]; then
                _hg_cmd_qguard;
                return 0;
            fi;
        else
            if [ "${COMP_WORDS[i]}" = -- ]; then
                _hg_cmd_qguard;
                return 0;
            fi;
        fi;
    done;
    return 1
}
_hg_paths () 
{ 
    local paths="$("$hg" paths 2>/dev/null | sed -e 's/ = .*$//')";
    COMPREPLY=(${COMPREPLY[@]:-} $(compgen -W '$paths' -- "$cur"))
}
_hg_repos () 
{ 
    local i;
    for i in $(compgen -d -- "$cur");
    do
        test ! -d "$i"/.hg || COMPREPLY=(${COMPREPLY[@]:-} "$i");
    done
}
_hg_shelves () 
{ 
    local shelves="$("$hg" unshelve -l . 2>/dev/null)";
    local IFS='
';
    COMPREPLY=(${COMPREPLY[@]:-} $(compgen -W '$shelves' -- "$cur"))
}
_hg_status () 
{ 
    local files="$("$hg" status -n$1 . 2>/dev/null)";
    local IFS='
';
    COMPREPLY=(${COMPREPLY[@]:-} $(compgen -W '$files' -- "$cur"))
}
_hg_tags () 
{ 
    local tags="$("$hg" tags -q 2>/dev/null)";
    local IFS='
';
    COMPREPLY=(${COMPREPLY[@]:-} $(compgen -W '$tags' -- "$cur"))
}
_hid2hci () 
{ 
    local cur;
    COMPREPLY=();
    cur=`_get_cword`;
    if [[ "$cur" == -* ]]; then
        COMPREPLY=($( compgen -W '-h --help -q --quiet -0 --tohci -1 \
            --tohid' -- "$cur" ));
    fi
}
_iconv () 
{ 
    local cur prev;
    COMPREPLY=();
    cur=`_get_cword`;
    prev=${COMP_WORDS[COMP_CWORD-1]};
    case "$prev" in 
        -@(f|t|-@(from|to)-code))
            COMPREPLY=($( compgen -W                 '$( iconv --list | sed -e "s@//@@;" )' -- "$cur" ));
            return 0
        ;;
    esac;
    if [[ "$cur" = -* ]]; then
        COMPREPLY=($( compgen -W '--from-code -f --to-code -t --list
            --output -o --verbose' -- "$cur" ));
        return 0;
    fi
}
_id () 
{ 
    local cur;
    COMPREPLY=();
    cur=`_get_cword`;
    if [[ "$cur" == -* ]]; then
        COMPREPLY=($( compgen -W '-a -g --group -G --groups -n --name\
            -r --real -u --user --help --version' -- "$cur" ));
    else
        COMPREPLY=($( compgen -u "$cur" ));
    fi
}
_identify () 
{ 
    local cur;
    COMPREPLY=();
    cur=`_get_cword`;
    _ImageMagick;
    if [[ "$cur" == -* ]]; then
        COMPREPLY=($( compgen -W '-alpha -antialias -authenticate \
            -channel -colorspace -crop -debug -define -density \
            -depth -extract -format -fuzz -gamma -help -interlace \
            -interpolate -limit -list -log -monitor -ping -quiet \
            -regard-warnings -respect-parenthesis \
            -sampling-factor -seed -set -size -strip -units \
            -verbose -version -virtual-pixel' -- "$cur" ));
    else
        if [[ "$cur" == +* ]]; then
            COMPREPLY=($( compgen -W '+debug' -- "$cur" ));
        else
            _filedir;
        fi;
    fi
}
_ifupdown () 
{ 
    local cur;
    COMPREPLY=();
    cur=`_get_cword`;
    if [ $COMP_CWORD -eq 1 ]; then
        _configured_interfaces;
        COMPREPLY=($(compgen -W '${COMPREPLY[@]}' -- "$cur"));
    fi;
    return 0
}
_import () 
{ 
    local cur;
    COMPREPLY=();
    cur=`_get_cword`;
    _ImageMagick;
    if [[ "$cur" == -* ]]; then
        COMPREPLY=($( compgen -W '-adjoin -annotate -border -channel \
            -colors -colorspace -comment -compress -crop -debug \
            -define -delay -density -depth -descend -display \
            -dispose -dither -encipher -encoding -endian -filter \
            -format -frame -geometry -gravity -help -identify \
            -interlace -interpolate -label -limit -list -log \
            -monitor -monochrome -negate -page -pause -pointsize \
            -quality -quantize -quiet -regard-warnings -repage \
            -resize -respect-parenthesis -rotate -sampling-factor \
            -scene -screen -seed -set -silent -snaps -strip \
            -thumbnail -transparent -transparent-color -treedepth \
            -trim -type -verbose -version -virtual-pixel \
            -window' -- "$cur" ));
    else
        if [[ "$cur" == +* ]]; then
            COMPREPLY=($( compgen -W '+debug' -- "$cur" ));
        else
            _filedir;
        fi;
    fi
}
_info () 
{ 
    local cur i infopath;
    COMPREPLY=();
    cur=`_get_cword`;
    _expand || return 0;
    if [[ "$cur" == */* ]]; then
        _filedir;
        return 0;
    fi;
    infopath='/usr/share/info';
    if [ "${INFOPATH: -1:1}" == ':' ]; then
        infopath=${INFOPATH}${infopath};
    else
        if [ ${INFOPATH:+set} ]; then
            infopath=$INFOPATH;
        fi;
    fi;
    infopath=$infopath:;
    if [ -n "$cur" ]; then
        infopath="${infopath//://$cur* }";
    else
        infopath="${infopath//:// }";
    fi;
    COMPREPLY=($( eval command ls "$infopath" 2>/dev/null ));
    COMPREPLY=(${COMPREPLY[@]##*/?(:)});
    for ((i=0 ; i < ${#COMPREPLY[@]} ; ++i ))
    do
        if [ "${COMPREPLY[$i]}" == 'dir' ]; then
            unset COMPREPLY[$i];
        fi;
    done;
    COMPREPLY=(${COMPREPLY[@]%.@(gz|bz2|xz|lzma)});
    COMPREPLY=($( compgen -W '${COMPREPLY[@]%.*}' -- "${cur//\\\\/}" ));
    return 0
}
_insmod () 
{ 
    local cur prev modpath;
    COMPREPLY=();
    cur=`_get_cword`;
    prev=${COMP_WORDS[COMP_CWORD-1]};
    if [ $1 = "modprobe" ] && [ "${COMP_WORDS[1]}" = "-r" ]; then
        _installed_modules "$cur";
        return 0;
    fi;
    if [[ "$cur" == */* ]]; then
        _filedir '@(?(k)o?(.gz))';
        return 0;
    fi;
    if [ $COMP_CWORD -gt 1 ] && [[ "${COMP_WORDS[COMP_CWORD-1]}" != -* ]]; then
        COMPREPLY=($( compgen -W "$( /sbin/modinfo -p ${COMP_WORDS[1]} |                 cut -d: -f1 )" -- "$cur" ));
    else
        _modules $(uname -r);
    fi;
    return 0
}
_installed_alternatives () 
{ 
    local admindir;
    for i in alternatives dpkg/alternatives rpm/alternatives;
    do
        [ -d /var/lib/$i ] && admindir=/var/lib/$i && break;
    done;
    for ((i=1; i < COMP_CWORD; i++ ))
    do
        if [[ "${COMP_WORDS[i]}" == --admindir ]]; then
            admindir=${COMP_WORDS[i+1]};
            break;
        fi;
    done;
    COMPREPLY=($( compgen -W '$( command ls $admindir )' -- "$cur" ))
}
_installed_modules () 
{ 
    COMPREPLY=($( compgen -W "$( PATH="$PATH:/sbin" lsmod |         awk '{if (NR != 1) print $1}' )" -- "$1" ))
}
_invoke_rc_d () 
{ 
    local cur prev sysvdir services options valid_options;
    cur=`_get_cword`;
    prev=${COMP_WORDS[COMP_CWORD-1]};
    [ -d /etc/rc.d/init.d ] && sysvdir=/etc/rc.d/init.d || sysvdir=/etc/init.d;
    services=($(echo $sysvdir/!(README*|*.sh|*.dpkg*|*.rpm@(orig|new|save))));
    services=(${services[@]#$sysvdir/});
    options=(--help --quiet --force --try-anyway --disclose-deny --query --no-fallback);
    if [[ ( $COMP_CWORD -eq 1 ) || ( "$prev" == --* ) ]]; then
        valid_options=($(         echo ${COMP_WORDS[@]} ${options[@]}         | tr " " "\n"         | sed -ne "/$( echo ${options[@]} | sed "s/ /\\\\|/g" )/p"         | sort | uniq -u         ));
        COMPREPLY=($( compgen -W '${valid_options[@]} ${services[@]}' -- "$cur" ));
    else
        if [ -x $sysvdir/$prev ]; then
            COMPREPLY=($( compgen -W '`sed -ne "y/|/ /; \
            s/^.*Usage:[ ]*[^ ]*[ ]*{*\([^}\"]*\).*$/\1/p" \
            $sysvdir/$prev`' -- "$cur" ));
        else
            COMPREPLY=();
        fi;
    fi;
    return 0
}
_ipmitool () 
{ 
    local cur prev;
    COMPREPLY=();
    cur=`_get_cword`;
    prev=${COMP_WORDS[COMP_CWORD-1]};
    case "$prev" in 
        -I)
            COMPREPLY=($( compgen -W 'open imb lan lanplus free' -- "$cur" ));
            return 0
        ;;
    esac;
    if [[ "$cur" == -* ]]; then
        COMPREPLY=($( compgen -W '-h -V -v -c -d -I -H -p -U -f -S -a \
            -e -C -k -y -K -A -P -E -K -m -b -r -B -T -l -o -O' -- "$cur" ));
    else
        COMPREPLY=($( compgen -W 'raw i2c spd lan chassis power event \
            mc sdr sensor fru gendev sel pef sol tsol isol user \
            channel session sunoem kontronoem picmg fwum firewall \
            exec set hpm ekanalyzer' -- "$cur" ));
    fi
}
_iptables () 
{ 
    local cur prev table chain;
    COMPREPLY=();
    cur=`_get_cword`;
    prev=${COMP_WORDS[COMP_CWORD-1]};
    chain='s/^Chain \([^ ]\+\).*$/\1/p';
    if [[ $COMP_LINE == *-t\ *filter* ]]; then
        table="-t filter";
    else
        if [[ $COMP_LINE == *-t\ *nat* ]]; then
            table="-t nat";
        else
            if [[ $COMP_LINE == *-t\ *mangle* ]]; then
                table="-t mangle";
            fi;
        fi;
    fi;
    _split_longopt;
    case "$prev" in 
        -*[AIDRPFXLZ])
            COMPREPLY=($( compgen -W '`iptables $table -nL | \
                sed -ne "s/^Chain \([^ ]\+\).*$/\1/p"`' -- "$cur" ))
        ;;
        -*t)
            COMPREPLY=($( compgen -W 'nat filter mangle' -- "$cur" ))
        ;;
        -j)
            if [ "$table" = "-t filter" -o "$table" = "" ]; then
                COMPREPLY=($( compgen -W 'ACCEPT DROP LOG ULOG REJECT \
                `iptables $table -nL | sed -ne "$chain" \
                -e "s/INPUT|OUTPUT|FORWARD|PREROUTING|POSTROUTING//"`' --                 "$cur" ));
            else
                if [ "$table" = "-t nat" ]; then
                    COMPREPLY=($( compgen -W 'ACCEPT DROP LOG ULOG REJECT \
                MIRROR SNAT DNAT MASQUERADE `iptables $table -nL | \
                sed -ne "$chain" -e "s/OUTPUT|PREROUTING|POSTROUTING//"`'                 -- "$cur" ));
                else
                    if [ "$table" = "-t mangle" ]; then
                        COMPREPLY=($( compgen -W 'ACCEPT DROP LOG ULOG REJECT \
                MARK TOS `iptables $table -nL | sed -ne "$chain" \
                -e "s/INPUT|OUTPUT|FORWARD|PREROUTING|POSTROUTING//"`' --                 "$cur" ));
                    fi;
                fi;
            fi
        ;;
        *)
            if [[ "$cur" == -* ]]; then
                COMPREPLY=($( compgen -W '-i -o -s -d -p -f -m --append \
                --delete --insert --replace --list --flush --zero --new \
                --delete-chain --policy --rename-chain --proto --source \
                --destination --in-interface --jump --match --numeric \
                --out-interface --table --verbose --line-numbers --exact \
                --fragment --modprobe --set-counters --version' -- "$cur"));
            fi
        ;;
    esac
}
_is_integer () 
{ 
    [ "$1" -eq "$1" ] > /dev/null 2>&1;
    return $?
}
_isql () 
{ 
    local cur;
    cur=`_get_cword`;
    [ -f "$ODBCINI" ] && COMPREPLY=($( grep \\["$cur" "$ODBCINI" | tr -d \\[\\] ))
}
_iwconfig () 
{ 
    local cur prev;
    COMPREPLY=();
    cur=`_get_cword`;
    prev=${COMP_WORDS[COMP_CWORD-1]};
    case $prev in 
        mode)
            COMPREPLY=($( compgen -W 'managed ad-hoc master \
                repeater secondary monitor' -- "$cur" ));
            return 0
        ;;
        essid)
            COMPREPLY=($( compgen -W 'on off any' -- "$cur" ));
            if [ -n "${COMP_IWLIST_SCAN:-}" ]; then
                COMPREPLY=("${COMPREPLY[@]}" $( compgen -W                     "$( iwlist ${COMP_WORDS[1]} scan |                     awk -F '\"' '/ESSID/ {print $2}' )" -- "$cur" ));
            fi;
            return 0
        ;;
        nwid)
            COMPREPLY=($( compgen -W 'on off' -- "$cur" ));
            return 0
        ;;
        channel)
            COMPREPLY=($( compgen -W "$( iwlist ${COMP_WORDS[1]} channel |                 awk '/^[[:space:]]*Channel/ {print $2}' )" -- "$cur" ));
            return 0
        ;;
        freq)
            COMPREPLY=($( compgen -W "$( iwlist ${COMP_WORDS[1]} channel |                 awk '/^[[:space:]]*Channel/ {print $4\"G\"}')" -- "$cur" ));
            return 0
        ;;
        ap)
            COMPREPLY=($( compgen -W 'on off any' -- "$cur" ));
            if [ -n "${COMP_IWLIST_SCAN:-}" ]; then
                COMPREPLY=("${COMPREPLY[@]}" $( compgen -W                     "$( iwlist ${COMP_WORDS[1]} scan |                     awk -F ': ' '/Address/ {print $2}' )" -- "$cur" ));
            fi;
            return 0
        ;;
        rate)
            COMPREPLY=($( compgen -W 'auto fixed' -- "$cur" ));
            COMPREPLY=("${COMPREPLY[@]}" $( compgen -W                 "$( iwlist ${COMP_WORDS[1]} rate |                 awk '/^[[:space:]]*[0-9]/ {print $1\"M\"}' )" -- "$cur" ));
            return 0
        ;;
        rts | frag)
            COMPREPLY=($( compgen -W 'auto fixed off' -- "$cur" ));
            return 0
        ;;
        key | enc)
            COMPREPLY=($( compgen -W 'off on open restricted' -- "$cur" ));
            return 0
        ;;
        power)
            COMPREPLY=($( compgen -W 'period timeout off on' -- "$cur" ));
            return 0
        ;;
        txpower)
            COMPREPLY=($( compgen -W 'off on auto' -- "$cur" ));
            return 0
        ;;
        retry)
            COMPREPLY=($( compgen -W 'limit lifetime' -- "$cur" ));
            return 0
        ;;
    esac;
    if [ $COMP_CWORD -eq 1 ]; then
        if [[ "$cur" == -* ]]; then
            COMPREPLY=($( compgen -W '--help --version' -- "$cur" ));
        else
            _available_interfaces -w;
        fi;
    else
        COMPREPLY=($( compgen -W 'essid nwid mode freq channel sens mode \
            ap nick rate rts frag enc key power txpower commit' -- "$cur" ));
    fi
}
_iwlist () 
{ 
    local cur prev;
    COMPREPLY=();
    cur=`_get_cword`;
    prev=${COMP_WORDS[COMP_CWORD-1]};
    if [ $COMP_CWORD -eq 1 ]; then
        if [[ "$cur" == -* ]]; then
            COMPREPLY=($( compgen -W '--help --version' -- "$cur" ));
        else
            _available_interfaces -w;
        fi;
    else
        COMPREPLY=($( compgen -W 'scan scanning freq frequency \
            channel rate bit bitrate key enc encryption power \
            txpower retry ap accesspoint peers event' -- "$cur" ));
    fi
}
_iwpriv () 
{ 
    local cur prev;
    COMPREPLY=();
    cur=`_get_cword`;
    prev=${COMP_WORDS[COMP_CWORD-1]};
    case "$prev" in 
        roam)
            COMPREPLY=($( compgen -W 'on off' -- "$cur" ));
            return 0
        ;;
        port)
            COMPREPLY=($( compgen -W 'ad-hoc managed' -- "$cur" ));
            return 0
        ;;
    esac;
    if [ $COMP_CWORD -eq 1 ]; then
        if [[ "$cur" == -* ]]; then
            COMPREPLY=($( compgen -W '--help --version' -- "$cur" ));
        else
            _available_interfaces -w;
        fi;
    else
        COMPREPLY=($( compgen -W '--all roam port' -- "$cur" ));
    fi
}
_iwspy () 
{ 
    local cur;
    COMPREPLY=();
    cur=`_get_cword`;
    if [ $COMP_CWORD -eq 1 ]; then
        if [[ "$cur" == -* ]]; then
            COMPREPLY=($( compgen -W '--help --version' -- "$cur" ));
        else
            _available_interfaces -w;
        fi;
    else
        COMPREPLY=($( compgen -W 'setthr getthr off' -- "$cur" ));
    fi
}
_jar () 
{ 
    local cur;
    COMPREPLY=();
    cur=`_get_cword`;
    if [ $COMP_CWORD = 1 ]; then
        COMPREPLY=($( compgen -W 'c t x u' -- "$cur" ));
        return 0;
    fi;
    case "${COMP_WORDS[1]}" in 
        *c*f)
            _filedir
        ;;
        *f)
            _filedir '?([ejw]ar|zip|[EJW]AR|ZIP)'
        ;;
        *)
            _filedir
        ;;
    esac
}
_java () 
{ 
    local cur prev i;
    COMPREPLY=();
    cur=`_get_cword`;
    prev=${COMP_WORDS[COMP_CWORD-1]};
    for ((i=1; i < $COMP_CWORD; i++))
    do
        case ${COMP_WORDS[$i]} in 
            -cp | -classpath)
                ((i++))
            ;;
            -*)

            ;;
            *)
                _filedir;
                return 0
            ;;
        esac;
    done;
    case $prev in 
        -@(cp|classpath))
            _java_path;
            return 0
        ;;
    esac;
    if [[ "$cur" == -* ]]; then
        COMPREPLY=($( compgen -W '-client -hotspot -server -classic \
            -cp -classpath -D -verbose -verbose:class \
            -verbose:gc -version:jni -version \
            -showversion -? -help -X -jar \
            -ea -enableassertions -da -disableassertions \
            -esa -enablesystemassertions \
            -dsa -disablesystemassertions ' -- "$cur" ));
    else
        if [[ "$prev" == -jar ]]; then
            _filedir jar;
        else
            _java_classes;
        fi;
    fi
}
_java_classes () 
{ 
    local classpath i;
    _java_find_classpath;
    cur=${cur//.//};
    for i in ${classpath//:/ };
    do
        if [ -r $i ] && [[ "$i" == *.@(jar|zip) ]]; then
            if type zipinfo &>/dev/null; then
                COMPREPLY=("${COMPREPLY[@]}" $( zipinfo -1                     "$i" "$cur*" 2>/dev/null |                     grep '^[^$]*\.class$' ));
            else
                COMPREPLY=("${COMPREPLY[@]}" $( jar tf "$i"                     "$cur" | grep '^[^$]*\.class$' ));
            fi;
        else
            if [ -d $i ]; then
                i=${i%/};
                COMPREPLY=("${COMPREPLY[@]}" $( find "$i" -type f                 -maxdepth 1 -path "$i/$cur*.class" 2>/dev/null |                 grep -v "\\$" | sed -e "s|^$i/||" ));
            fi;
        fi;
    done;
    COMPREPLY=(${COMPREPLY[@]%.class});
    COMPREPLY=(${COMPREPLY[@]//\//.})
}
_java_find_classpath () 
{ 
    local i;
    for ((i=1; i < COMP_CWORD; i++ ))
    do
        if [[ "${COMP_WORDS[i]}" == -@(cp|classpath) ]]; then
            classpath=${COMP_WORDS[i+1]};
            break;
        fi;
    done;
    [ -z "$classpath" ] && classpath=$CLASSPATH;
    [ -z "$classpath" ] && classpath=.
}
_java_find_sourcepath () 
{ 
    local i;
    for ((i=1; i < COMP_CWORD; i++ ))
    do
        if [[ "${COMP_WORDS[i]}" == -sourcepath ]]; then
            sourcepath=${COMP_WORDS[i+1]};
            break;
        fi;
    done;
    if [ -z "$sourcepath" ]; then
        _java_find_classpath;
        sourcepath=$classpath;
    fi
}
_java_packages () 
{ 
    local sourcepath i;
    _java_find_sourcepath;
    cur=${cur//.//};
    for i in ${sourcepath//:/ };
    do
        if [ -d $i ]; then
            COMPREPLY=("${COMPREPLY[@]}" $( command ls -F -d                 $i/$cur* 2>/dev/null | sed -e 's|^'$i'/||' ));
        fi;
    done;
    COMPREPLY=($( echo "${COMPREPLY[@]}" | tr " " "\n" | grep "/$" ));
    COMPREPLY=(${COMPREPLY[@]%/});
    cur=${COMPREPLY[@]//\//.}
}
_java_path () 
{ 
    cur=${cur##*:};
    _filedir '@(jar|zip)'
}
_javac () 
{ 
    COMPREPLY=();
    local cur prev;
    cur=`_get_cword`;
    prev=${COMP_WORDS[COMP_CWORD-1]};
    case $prev in 
        -d)
            _filedir -d;
            return 0
        ;;
        -@(classpath|bootclasspath|sourcepath|extdirs))
            _java_path;
            return 0
        ;;
    esac;
    if [[ "$cur" == -* ]]; then
        COMPREPLY=($( compgen -W '-g -g:none -g:lines -g:vars\
            -g:source -O -nowarn -verbose -deprecation -classpath\
            -sourcepath -bootclasspath -extdirs -d -encoding -source\
            -target -help' -- "$cur" ));
    else
        _filedir java;
    fi
}
_javadoc () 
{ 
    COMPREPLY=();
    local cur prev;
    cur=`_get_cword`;
    prev=${COMP_WORDS[COMP_CWORD-1]};
    case $prev in 
        -@(overview|helpfile|stylesheetfile))
            _filedir;
            return 0
        ;;
        -d)
            _filedir -d;
            return 0
        ;;
        -@(classpath|bootclasspath|docletpath|sourcepath|extdirs))
            _java_path;
            return 0
        ;;
    esac;
    if [[ "$cur" == -* ]]; then
        COMPREPLY=($( compgen -W '-overview -public -protected \
            -package -private -help -doclet -docletpath \
            -sourcepath -classpath -exclude -subpackages \
            -breakiterator -bootclasspath -source -extdirs \
            -verbose -locale -encoding -J -d -use -version \
            -author -docfilessubdirs -splitindex \
            -windowtitle -doctitle -header -footer -bottom \
            -link -linkoffline -excludedocfilessubdir \
            -group -nocomment -nodeprecated -noqualifier \
            -nosince -nodeprecatedlist -notree -noindex \
            -nohelp -nonavbar -quiet -serialwarn -tag \
            -taglet -tagletpath -charset -helpfile \
            -linksource -stylesheetfile -docencoding' -- "$cur" ));
    else
        _filedir java;
        _java_packages;
    fi
}
_kernel_versions () 
{ 
    COMPREPLY=($( compgen -W '$( command ls /lib/modules )' -- "$cur" ))
}
_kill () 
{ 
    local cur;
    COMPREPLY=();
    cur=`_get_cword`;
    if [ $COMP_CWORD -eq 1 ] && [[ "$cur" == -* ]]; then
        _signals;
    else
        _pids;
    fi
}
_killall () 
{ 
    local cur;
    COMPREPLY=();
    cur=`_get_cword`;
    if [ $COMP_CWORD -eq 1 ] && [[ "$cur" == -* ]]; then
        _signals;
    else
        _pnames;
    fi;
    return 0
}
_known_hosts () 
{ 
    local options;
    COMPREPLY=();
    [ "$1" = -a ] || [ "$2" = -a ] && options=-a;
    [ "$1" = -c ] || [ "$2" = -c ] && options="$options -c";
    _known_hosts_real $options "$(_get_cword)"
}
_known_hosts_real () 
{ 
    local configfile flag prefix;
    local cur curd awkcur user suffix aliases hosts i host;
    local -a kh khd config;
    local OPTIND=1;
    while getopts "acF:p:" flag "$@"; do
        case $flag in 
            a)
                aliases='yes'
            ;;
            c)
                suffix=':'
            ;;
            F)
                configfile=$OPTARG
            ;;
            p)
                prefix=$OPTARG
            ;;
        esac;
    done;
    [ $# -lt $OPTIND ] && echo "error: $FUNCNAME: missing mandatory argument CWORD";
    cur=${!OPTIND};
    let "OPTIND += 1";
    [ $# -ge $OPTIND ] && echo "error: $FUNCNAME("$@"): unprocessed arguments:" $(while [ $# -ge $OPTIND ]; do echo ${!OPTIND}; shift; done);
    [[ $cur == *@* ]] && user=${cur%@*}@ && cur=${cur#*@};
    kh=();
    if [ -n "$configfile" ]; then
        [ -r "$configfile" ] && config=("${config[@]}" "$configfile");
    else
        [ -r /etc/ssh/ssh_config ] && config=("${config[@]}" "/etc/ssh/ssh_config");
        [ -r "${HOME}/.ssh/config" ] && config=("${config[@]}" "${HOME}/.ssh/config");
        [ -r "${HOME}/.ssh2/config" ] && config=("${config[@]}" "${HOME}/.ssh2/config");
    fi;
    if [ ${#config[@]} -gt 0 ]; then
        local OIFS=$IFS IFS='
';
        local -a tmpkh;
        tmpkh=($( sed -ne 's/^[ \t]*\([Gg][Ll][Oo][Bb][Aa][Ll]\|[Uu][Ss][Ee][Rr]\)[Kk][Nn][Oo][Ww][Nn][Hh][Oo][Ss][Tt][Ss][Ff][Ii][Ll][Ee]['"$'\t '"']*\(.*\)$/\2/p' "${config[@]}" | sort -u ));
        for i in "${tmpkh[@]//\"/}";
        do
            i=$( eval echo "$i" );
            [ -r "$i" ] && kh=("${kh[@]}" "$i");
        done;
        IFS=$OIFS;
    fi;
    if [ -z "$configfile" ]; then
        [ -r /etc/ssh/ssh_known_hosts ] && kh=("${kh[@]}" /etc/ssh/ssh_known_hosts);
        [ -r /etc/ssh/ssh_known_hosts2 ] && kh=("${kh[@]}" /etc/ssh/ssh_known_hosts2);
        [ -r /etc/known_hosts ] && kh=("${kh[@]}" /etc/known_hosts);
        [ -r /etc/known_hosts2 ] && kh=("${kh[@]}" /etc/known_hosts2);
        [ -d /etc/ssh2/knownhosts ] && khd=("${khd[@]}" /etc/ssh2/knownhosts/*pub);
    fi;
    if [ -z "$configfile" ]; then
        [ -r ~/.ssh/known_hosts ] && kh=("${kh[@]}" ~/.ssh/known_hosts);
        [ -r ~/.ssh/known_hosts2 ] && kh=("${kh[@]}" ~/.ssh/known_hosts2);
        [ -d ~/.ssh2/hostkeys ] && khd=("${khd[@]}" ~/.ssh2/hostkeys/*pub);
    fi;
    if [ ${#kh[@]} -gt 0 -o ${#khd[@]} -gt 0 -o -n "$configfile" ]; then
        awkcur=${cur//\//\\\/};
        awkcur=${awkcur//\./\\\.};
        curd=$awkcur;
        if [[ "$awkcur" == [0-9]*.* ]]; then
            awkcur="^$awkcur.*";
        else
            if [[ "$awkcur" == [0-9]* ]]; then
                awkcur="^$awkcur.*\.";
            else
                if [ -z "$awkcur" ]; then
                    awkcur="[a-z.]";
                else
                    awkcur="^$awkcur";
                fi;
            fi;
        fi;
        if [ ${#kh[@]} -gt 0 ]; then
            COMPREPLY=($( awk 'BEGIN {FS=","}
            /^\s*[^|\#]/ {for (i=1; i<=2; ++i) { \
            gsub(" .*$", "", $i); \
            gsub("[\\[\\]]", "", $i); \
            gsub(":[0-9]+$", "", $i); \
            if ($i ~ /'"$awkcur"'/) {print $i} \
            }}' "${kh[@]}" 2>/dev/null ));
        fi;
        if [ ${#khd[@]} -gt 0 ]; then
            for i in "${khd[@]}";
            do
                if [[ "$i" == *key_22_$awkcurd*.pub ]] && [ -r "$i" ]; then
                    host=${i/#*key_22_/};
                    host=${host/%.pub/};
                    COMPREPLY=("${COMPREPLY[@]}" $host);
                fi;
            done;
        fi;
        if [ ${#config[@]} -gt 0 ] && [ -n "$aliases" ]; then
            local host_aliases=$( sed -ne 's/^[ \t]*[Hh][Oo][Ss][Tt]\([Nn][Aa][Mm][Ee]\)\?['"$'\t '"']\+\([^#*?]*\)\(#.*\)\?$/\2/p' "${config[@]}" );
            hosts=$( compgen -W "$host_aliases" -- "$cur" );
            COMPREPLY=("${COMPREPLY[@]}" $hosts);
        fi;
        for ((i=0; i < ${#COMPREPLY[@]}; i++ ))
        do
            COMPREPLY[i]=$prefix$user${COMPREPLY[i]}$suffix;
        done;
    fi;
    if [ -n "${COMP_KNOWN_HOSTS_WITH_HOSTFILE-1}" ]; then
        COMPREPLY=("${COMPREPLY[@]}" $( compgen -A hostname -P "$prefix$user" -S "$suffix" -- "$cur" ));
    fi;
    return 0
}
_l2ping () 
{ 
    local cur prev;
    COMPREPLY=();
    cur=`_get_cword`;
    prev=${COMP_WORDS[COMP_CWORD-1]};
    case $prev in 
        -i)
            _bluetooth_devices;
            return 0
        ;;
    esac;
    if [[ "$cur" == -* ]]; then
        COMPREPLY=($( compgen -W '-i -s -c -t -f -r' -- "$cur" ));
    else
        _bluetooth_adresses;
    fi
}
_lastlog () 
{ 
    local cur prev split=false;
    COMPREPLY=();
    cur=`_get_cword`;
    prev=${COMP_WORDS[COMP_CWORD-1]};
    _split_longopt && split=true;
    case "$prev" in 
        -b | --before | -h | --help | -t | --time)
            return 0
        ;;
        -u | --user)
            COMPREPLY=($( compgen -u -- "$cur" ));
            return 0
        ;;
    esac;
    $split && return 0;
    if [[ "$cur" == -* ]]; then
        COMPREPLY=($( compgen -W '-b --before -h --help -t --time \
            -u --user' -- "$cur" ));
        return 0;
    fi
}
_lftp () 
{ 
    local cur;
    COMPREPLY=();
    cur=`_get_cword`;
    if [ $COMP_CWORD -eq 1 ] && [ -f ~/.lftp/bookmarks ]; then
        COMPREPLY=($( compgen -W '$( sed -ne "s/^\(.*\)''	''.*$/\1/p" \
            ~/.lftp/bookmarks )' -- "$cur" ));
    fi;
    return 0
}
_longopt () 
{ 
    local cur prev;
    cur=`_get_cword`;
    prev=${COMP_WORDS[COMP_CWORD-1]};
    if _split_longopt; then
        case "$prev" in 
            *[Dd][Ii][Rr]*)
                _filedir -d
            ;;
            *[Ff][Ii][Ll][Ee]*)
                _filedir
            ;;
        esac;
        return 0;
    fi;
    if [[ "$cur" == -* ]]; then
        COMPREPLY=($( compgen -W "$( $1 --help 2>&1 | sed -e '/--/!d'             -e 's/.*\(--[-A-Za-z0-9]\+\).*/\1/' |sort -u )"            -- "$cur" ));
    else
        if [[ "$1" == rmdir ]]; then
            _filedir -d;
        else
            _filedir;
        fi;
    fi
}
_look () 
{ 
    local cur;
    COMPREPLY=();
    cur=`_get_cword`;
    if [ $COMP_CWORD = 1 ]; then
        COMPREPLY=($( compgen -W '$(look "$cur" 2>/dev/null)' ));
    fi
}
_lzma () 
{ 
    local cur prev xspec;
    COMPREPLY=();
    cur=`_get_cword`;
    prev=${COMP_WORDS[COMP_CWORD-1]};
    if [[ "$cur" == -* ]]; then
        COMPREPLY=($( compgen -W '-c -d -f -h -k -L -q -s \
            -v -V -z -1 -2 -3 -4 -5 -6 -7 -8 -9 \
            --help --decompress --compress --keep --force \
            --test --stdout --quiet --verbose --license \
            --version --small --fast --best --text' -- "$cur" ));
        return 0;
    fi;
    local IFS='	
';
    xspec="*.lzma";
    if [[ "$prev" == --* ]]; then
        [[ "$prev" == --decompress || "$prev" == --list || "$prev" == --test ]] && xspec="!"$xspec;
        [[ "$prev" == --compress ]] && xspec=;
    else
        if [[ "$prev" == -* ]]; then
            [[ "$prev" == -*[dt]* ]] && xspec="!"$xspec;
            [[ "$prev" == -*z* ]] && xspec=;
        fi;
    fi;
    _expand || return 0;
    COMPREPLY=($( compgen -f -X "$xspec" -- "$cur" ) $( compgen -d -- "$cur" ))
}
_make () 
{ 
    local file makef makef_dir="." makef_inc cur prev i split=false;
    COMPREPLY=();
    cur=`_get_cword`;
    prev=${COMP_WORDS[COMP_CWORD-1]};
    _split_longopt && split=true;
    case $prev in 
        -@(f|o|W|-@(?(make|old-|new-)file|assume-@(old|new)|what-if)))
            _filedir;
            return 0
        ;;
        -I | -C | --directory | --include-dir)
            _filedir -d;
            return 0
        ;;
    esac;
    $split && return 0;
    if [[ "$cur" == -* ]]; then
        COMPREPLY=($( compgen -W '-b -m -B -C -d -e -f -h -i -I\
            -j -l -k -n -o -p -q -r -R - s -S -t -v -w -W \
            --always-make --directory --debug \
            --environment-overrides --file --makefile --help \
            --ignore-errors --include-dir --jobs --load-average \
            --max-load --keep-going --just-print --dry-run \
            --recon --old-file --assume-old --print-data-base \
            --question --no-builtin-rules --no-builtin-variables \
            --silent --quiet --no-keep-goind --stop --touch \
            --version --print-directory --no-print-directory \
            --what-if --new-file --assume-new \
            --warn-undefined-variables' -- "$cur" ));
    else
        for ((i=0; i < ${#COMP_WORDS[@]}; i++ ))
        do
            if [[ ${COMP_WORDS[i]} == -C ]]; then
                eval makef_dir=${COMP_WORDS[i+1]};
                break;
            fi;
        done;
        for ((i=0; i < ${#COMP_WORDS[@]}; i++ ))
        do
            if [[ ${COMP_WORDS[i]} == -f ]]; then
                eval makef=${COMP_WORDS[i+1]};
                break;
            fi;
        done;
        [ -n "$makef" ] && makef="-f ${makef}";
        [ -n "$makef_dir" ] && makef_dir="-C ${makef_dir}";
        COMPREPLY=($( compgen -W "$( make -qp $makef $makef_dir 2>/dev/null |             awk -F':' '/^[a-zA-Z0-9][^$#\/\t=]*:([^=]|$)/ \
            {split($1,A,/ /);for(i in A)print A[i]}' )"             -- "$cur" ));
    fi
}
_man () 
{ 
    local cur i prev sect manpath manext mansect uname;
    manext="@([0-9lnp]|[0-9][px]|man|3pm)?(.@(gz|bz2|lzma))";
    mansect="@([0-9lnp]|[0-9][px]|3pm)";
    COMPREPLY=();
    cur=`_get_cword`;
    prev=${COMP_WORDS[COMP_CWORD-1]};
    if [[ "$prev" == -l ]]; then
        _filedir $manext;
        return 0;
    fi;
    _expand || return 0;
    if [[ "$cur" == */* ]]; then
        _filedir $manext;
        return 0;
    fi;
    uname=$( uname -s );
    if [[ $uname == @(Linux|GNU|GNU/*|FreeBSD|Cygwin|CYGWIN_*) ]]; then
        manpath=$( manpath 2>/dev/null || command man --path );
    else
        manpath=$MANPATH;
    fi;
    if [ -z "$manpath" ]; then
        COMPREPLY=($( compgen -c -- "$cur" ));
        return 0;
    fi;
    [[ "$prev" == $mansect ]] && sect=$prev || sect='*';
    manpath=$manpath:;
    if [ -n "$cur" ]; then
        manpath="${manpath//://*man$sect/$cur* } ${manpath//://*cat$sect/$cur* }";
    else
        manpath="${manpath//://*man$sect/ } ${manpath//://*cat$sect/ }";
    fi;
    COMPREPLY=($( eval command ls "$manpath" 2>/dev/null ));
    COMPREPLY=(${COMPREPLY[@]##*/?(:)});
    COMPREPLY=(${COMPREPLY[@]%.@(gz|bz2|lzma)});
    COMPREPLY=($( compgen -W '${COMPREPLY[@]%.*}' -- "${cur//\\\\/}" ));
    if [[ "$prev" != $mansect ]]; then
        local start=${#COMPREPLY[@]};
        _filedir $manext;
        for ((i=$start; i < ${#COMPREPLY[@]}; i++ ))
        do
            [[ ${COMPREPLY[i]} == */* ]] || COMPREPLY[i]=./${COMPREPLY[i]};
        done;
    fi;
    return 0
}
_mii_tool () 
{ 
    local cur prev split=false;
    COMPREPLY=();
    cur=`_get_cword`;
    prev=${COMP_WORDS[COMP_CWORD-1]};
    _split_longopt && split=true;
    case $prev in 
        -F | --force)
            COMPREPLY=($( compgen -W '100baseTx-FD 100baseTx-HD \
                10baseT-FD 10baseT-HD' -- "$cur" ));
            return 0
        ;;
        -A | --advertise)
            COMPREPLY=($( compgen -W '100baseT4 100baseTx-FD 100baseTx-HD \
                10baseT-FD 10baseT-HD' -- "$cur" ));
            return 0
        ;;
    esac;
    $split && return 0;
    if [[ "$cur" == -* ]]; then
        COMPREPLY=($( compgen -W '-v --verbose -V --version -R \
            --reset -r --restart -w  --watch -l --log -A \
            --advertise -F --force' -- "$cur" ));
    else
        _available_interfaces -a;
    fi
}
_minicom () 
{ 
    local cur prev confdir;
    COMPREPLY=();
    cur=`_get_cword`;
    prev=${COMP_WORDS[COMP_CWORD-1]};
    case $prev in 
        -@(a|c))
            COMPREPLY=($( compgen -W 'on off' -- "$cur" ));
            return 0
        ;;
        -@(S|C))
            _filedir;
            return 0
        ;;
        -P)
            COMPREPLY=($( command ls /dev/tty* ));
            COMPREPLY=($( compgen -W '${COMPREPLY[@]} ${COMPREPLY[@]#/dev/}'                 -- "$cur" ));
            return 0
        ;;
    esac;
    if [[ "$cur" == -* ]]; then
        COMPREPLY=($( compgen -W '-s -o -m -M -z -l -L -w -a -t \
            -c -S -d -p -C -T -7 -8' -- "$cur" ));
        return 0;
    else
        [ -n "$( command ls /etc/minirc.* 2>/dev/null)" ] && confdir=/etc;
        [ -n "$( command ls /etc/minicom/minirc.* 2>/dev/null)" ] && confdir=/etc/minicom;
        if [ -n "$confdir" ]; then
            COMPREPLY=($( compgen -W '$( command ls $confdir/minirc.* | \
                sed -e "s|$confdir/minirc.||")' -- "$cur" ));
            return 0;
        fi;
    fi
}
_mkisofs () 
{ 
    local cur prev;
    COMPREPLY=();
    cur=`_get_cword`;
    prev=${COMP_WORDS[COMP_CWORD-1]};
    case "$prev" in 
        -@(o|abstract|biblio|check-session|copyright|log-file|root-info|prep-boot|*-list))
            _filedir;
            return 0
        ;;
        -*-charset)
            COMPREPLY=($( compgen -W '$( mkisofs -input-charset \
                    help 2>&1 | tail -n +3 )' -- "$cur" ));
            return 0
        ;;
        -uid)
            _uids;
            return 0
        ;;
        -gid)
            _gids;
            return 0
        ;;
    esac;
    if [[ "$cur" == -* ]]; then
        COMPREPLY=($( compgen -W '-abstract -A -allow-lowercase \
            -allow-multidot -biblio -cache-inodes \
            -no-cache-inodes -b -eltorito-alt-boot -B -G \
            -hard-disk-boot -no-emul-boot -no-boot \
            -boot-load-seg -boot-load-size \
            -boot-info-table -C -c -check-oldname \
            -check-session -copyright -d -D -dir-mode \
            -dvd-video -f -file-mode -gid -gui \
            -graft-points -hide -hide-list -hidden \
            -hidden-list -hide-joliet -hide-joliet-list \
            -hide-joliet-trans-tbl -hide-rr-moved \
            -input-charset -output-charset -iso-level -J \
            -joliet-long -jcharset -l -L -log-file -m \
            -exclude-list -max-iso9660-filenames -M -N \
            -new-dir-mode -nobak -no-bak -force-rr -no-rr \
            -no-split-symlink-components \
            -no-split-symlink-fields -o -pad -no-pad \
            -path-list -P -p -print-size -quiet -R -r \
            -relaxed-filenames -sort -split-output \
            -stream-media-size -stream-file-name -sysid -T\
            -table-name -ucs-level -udf -uid \
            -use-fileversion -U -no-iso-translate -V \
            -volset -volset-size -volset-seqno -v -x -z \
            -hfs -apple -map -magic -hfs-creator \
            -hfs-type -probe -no-desktop -mac-name \
            -boot-hfs-file -part -auto -cluster-size \
            -hide-hfs -hide-hfs-list -hfs-volid \
            -icon-position -root-info -prep-boot \
            -input-hfs-charset -output-hfs-charset \
            -hfs-unlock -hfs-bless -hfs-parms --cap \
            --netatalk --double --ethershare --ushare \
            --exchange --sgi --xinet --macbin --single \
            --dave --sfm --osx-double --osx-hfs' -- "$cur" ));
    else
        _filedir;
    fi
}
_modules () 
{ 
    local modpath;
    modpath=/lib/modules/$1;
    COMPREPLY=($( compgen -W "$( command ls -R $modpath |         sed -ne 's/^\(.*\)\.k\?o\(\|.gz\)$/\1/p' )" -- "$cur" ))
}
_mogrify () 
{ 
    local cur;
    COMPREPLY=();
    cur=`_get_cword`;
    _ImageMagick;
    if [[ "$cur" == -* ]]; then
        COMPREPLY=($( compgen -W '-adaptive-blur -adaptive-resize \
            -adaptive-sharpen -adjoin -affine -alpha -annotate \
            -antialias -attenuate -authenticate -auto-orient \
            -background -bias -black-point-compensation \
            -black-threshold -blue-primary -blur -border \
            -bordercolor -caption -channel -charcoal -chop -clip \
            -clip-mask -clip-path -clut -colorize -colors \
            -colorspace -comment -compose -compress -contrast \
            -contrast-stretch -convolve -cycle -debug -decipher \
            -define -delay -density -depth -despeckle -display \
            -dispose -distort -dither -draw -edge -emboss \
            -encipher -encoding -endian -enhance -equalize \
            -evaluate -extent -extract -family -fill -filter \
            -flip -floodfill -flop -font -format -frame -fuzz \
            -gamma -gaussian-blur -geometry -gravity \
            -green-primary -help -identify -implode -intent \
            -interlace -interpolate -label -lat -layers -level \
            -limit -linear-stretch -liquid-rescale -list -log \
            -loop -mask -mattecolor -median -modulate -monitor \
            -monochrome -motion-blur -negate -noise -normalize \
            -opaque -ordered-dither -orient -page -paint -path \
            -ping -pointsize -polaroid -posterize -preview -print \
            -profile -quality -quantize -quiet -radial-blur \
            -raise -random-threshold -recolor -red-primary \
            -regard-warnings -region -render -repage -resample \
            -resize -roll -rotate -sample -sampling-factor -scale \
            -scene -seed -segment -sepia-tone -set -shade -shadow \
            -sharpen -shave -shear -sigmoidal-contrast -size \
            -sketch -solarize -splice -spread -stretch -strip \
            -stroke -strokewidth -style -swirl -taint -texture \
            -threshold -thumbnail -tile -tile-offset -tint \
            -transform -transparent -transparent-color -transpose \
            -transverse -treedepth -trim -type -undercolor \
            -unique-colors -units -unsharp -verbose -version \
            -view -vignette -virtual-pixel -wave -weight \
            -white-point -white-threshold' -- "$cur" ));
    else
        if [[ "$cur" == +* ]]; then
            COMPREPLY=($( compgen -W '+compress +contrast +debug +dither \
            +endian +gamma +label +map +mask +matte +negate +page \
            +raise' -- "$cur" ));
        else
            _filedir;
        fi;
    fi
}
_montage () 
{ 
    local cur;
    COMPREPLY=();
    cur=`_get_cword`;
    _ImageMagick;
    if [[ "$cur" == -* ]]; then
        COMPREPLY=($( compgen -W '-adjoin -affine -alpha \
            -authenticate -background -blue-primary -blur -border \
            -bordercolor -borderwidth -caption -channel -clone \
            -coalesce -colors -colorspace -comment -compose \
            -compress -crop -debug -define -density -depth \
            -display -dispose -dither -draw -encoding -endian \
            -extract -fill -filter -flatten -flip -flop -font \
            -format -frame -gamma -geometry -gravity \
            -green-primary -help -identify -interlace \
            -interpolate -label -limit -list -log -mattecolor \
            -mode -monitor -monochrome -origin -page -pointsize \
            -polaroid -profile -quality -quantize -quiet \
            -red-primary -regard-warnings -repage -resize \
            -respect-parenthesis -rotate -sampling-factor -scenes \
            -seed -set -shadow -size -strip -stroke -texture \
            -thumbnail -tile -title -transform -transparent \
            -transparent-color -treedepth -trim -type -units \
            -verbose -version -virtual-pixel \
            -white-point' -- "$cur" ));
    else
        if [[ "$cur" == +* ]]; then
            COMPREPLY=($( compgen -W '+adjoin +compress +debug +dither \
            +endian +gamma +label +matte +page' -- "$cur" ));
        else
            _filedir;
        fi;
    fi
}
_mount () 
{ 
    local cur i sm host prev;
    COMPREPLY=();
    cur=`_get_cword`;
    [[ "$cur" == \\ ]] && cur="/";
    prev=${COMP_WORDS[COMP_CWORD-1]};
    for i in {,/usr}/{,s}bin/showmount;
    do
        [ -x $i ] && sm=$i && break;
    done;
    if [ -n "$sm" ] && [[ "$cur" == *:* ]]; then
        COMPREPLY=($( compgen -W "$( $sm -e ${cur%%:*} | sed 1d |                 awk '{print $1}' )" -- "$cur" ));
    else
        if [[ "$cur" == //* ]]; then
            host=${cur#//};
            host=${host%%/*};
            if [ -n "$host" ]; then
                COMPREPLY=($( compgen -P "//$host" -W                     "$( smbclient -d 0 -NL $host 2>/dev/null |
                    sed -ne '/^['"$'\t '"']*Sharename/,/^$/p' |
                    sed -ne '3,$s|^[^A-Za-z]*\([^'"$'\t '"']*\).*$|/\1|p' )"                     -- "${cur#//$host}" ));
            fi;
        else
            if [ -r /etc/vfstab ]; then
                COMPREPLY=($( compgen -W "$( awk '! /^[ \t]*#/ {if ($3 ~ /\//) print $3}' /etc/vfstab )" -- "$cur" ));
            else
                if [ ! -e /etc/fstab ]; then
                    COMPREPLY=($( compgen -W "$( mount | awk '! /^[ \t]*#/ {if ($3 ~ /\//) print $3}' )" -- "$cur" ));
                else
                    if [ $prev = -L ]; then
                        COMPREPLY=($( compgen -W '$(sed -ne "s/^[[:space:]]*LABEL=\([^[:space:]]*\).*/\1/p" /etc/fstab )' -- "$cur" ));
                    else
                        if [ $prev = -U ]; then
                            COMPREPLY=($( compgen -W '$(sed -ne "s/^[[:space:]]*UUID=\([^[:space:]]*\).*/\1/p" /etc/fstab )' -- "$cur" ));
                        else
                            COMPREPLY=($( compgen -W "$( awk '! /^[ \t]*#/ {if ($2 ~ /\//) print $2}' /etc/fstab )" -- "$cur" ));
                        fi;
                    fi;
                fi;
            fi;
        fi;
    fi;
    return 0
}
_mplayer () 
{ 
    local cmd cur prev skinsdir IFS=' 	
' i j k=0;
    COMPREPLY=();
    cmd=${COMP_WORDS[0]};
    cur=`_get_cword`;
    prev=${COMP_WORDS[COMP_CWORD-1]};
    case "$prev" in 
        -@([av][cfo]|[av]fm|vop|fstype|demuxer|o[av]c|of|profile))
            _mplayer_options_list $cmd $prev;
            return 0
        ;;
        -audiofile)
            _filedir '@(mp3|MP3|mpg|MPG|ogg|OGG|w?(a)v|W?(A)V|mid|MID|flac|FLAC|mka|MKA|ape|APE)';
            return 0
        ;;
        -font)
            _filedir '@(desc|ttf)';
            return 0
        ;;
        -sub)
            _filedir '@(srt|SRT|sub|SUB|txt|TXT|utf|UTF|rar|RAR|mpsub|smi|js|ssa|SSA|ass|ASS)';
            return 0
        ;;
        -vobsub)
            _filedir '@(idx|IDX|ifo|IFO|sub|SUB)';
            IFS='	
';
            COMPREPLY=($( for i in "${COMPREPLY[@]}"; do
                        if [ -f $i -a -r $i ]; then
                            echo ${i%.*}
                        else
                            echo $i
                        fi
                       done ));
            IFS=' 	
';
            return 0
        ;;
        -ifo)
            _filedir '@(ifo|IFO)';
            return 0
        ;;
        -cuefile)
            _filedir '@(bin|BIN|cue|CUE)';
            return 0
        ;;
        -skin)
            if [ -n "$MPLAYER_SKINS_DIR" ]; then
                skinsdir=$MPLAYER_SKINS_DIR;
            else
                skinsdir=/usr/share/mplayer/Skin;
            fi;
            IFS='	
';
            for i in ~/.mplayer/Skin $skinsdir;
            do
                if [ -d $i -a -r $i ]; then
                    for j in $( compgen -d $i/$cur );
                    do
                        COMPREPLY[$k]=${j#$i/};
                        k=$((++k));
                    done;
                fi;
            done;
            IFS=' 	
';
            return 0
        ;;
        -@(mixer|@(cdrom|dvd)-device|dvdauth|fb|zrdev))
            cur=${cur:=/dev/};
            _filedir;
            return 0
        ;;
        -@(edl?(out)|lircconf|menu-cfg|playlist|csslib|dumpfile) | -@(subfile|vobsub|aofile|fbmodeconfig|include|o|dvdkey) | -passlogfile)
            _filedir;
            return 0
        ;;
        -@(auto@(q|sync)|loop|menu-root|speed|sstep|aid|alang) | -@(?(@(audio|sub)-)demuxer|bandwidth|cache|chapter) | -@(dvd?(angle)|fps|frames|mc|passwd|user|sb|srate|ss|vcd) | -@(vi?(d|vo)|ffactor|sid|slang|spu@(align|aa|gauss)) | -@(vobsubid|delay|bpp|brightness|contrast|dfbopts|display) | -@(fbmode|geometry|guiwid|hue|icelayer|screen[wh]|wid) | -@(monitor@(aspect|-@(dotclock|[hv]freq))|panscan|saturation) | -@(xineramascreen|zr@(crop|norm|quality|[xy]doff|[vh]dec)) | -@(aspect|pp|x|y|xy|z|stereo|audio-@(density|delay|preload)) | -@(endpos|osdlevel|ffourcc|sws|channels|skiplimit|format) | -@(ofps|aa@(driver|@(osd|sub)color)|vobsubout?(i@(ndex|d))) | -sub@(-bg-@(alpha|color)|cp|delay|fps|pos|align|width) | -sub@(font-@(blur|outline|autoscale|encoding|@(osd|text)-scale)))
            return 0
        ;;
        -lavdopts)
            COMPREPLY=($( compgen -W 'ec er= bug= idct= gray' -- "$cur" ));
            return 0
        ;;
        -lavcopts)
            COMPREPLY=($( compgen -W 'vcodec= vqmin= vqscale= vqmax= mbqmin= \
                mbqmax= vqdiff= vmax_b_frames= vme= vhq v4mv keyint= \
                vb_strategy= vpass= aspect= vbitrate= vratetol= vrc_maxrate= \
                vrc_minrate= vrc_buf_size= vb_qfactor= vi_qfactor= vb_qoffset= \
                vi_qoffset= vqblur= vqcomp= vrc_eq= vrc_override= \
                vrc_init_cplx= vqsquish= vlelim= vcelim= vstrict= vdpart \
                vpsize= gray vfdct= idct= lumi_mask= dark_mask= tcplx_mask= \
                scplx_mask= naq ildct format= pred qpel precmp= cmp= subcmp= \
                predia= dia= trell last_pred= preme= subq= psnr mpeg_quant aic \
                umv' -- "$cur" ));
            return 0
        ;;
        -ssf)
            COMPREPLY=($( compgen -W 'lgb= cgb= ls= cs= chs= cvs=' -- "$cur" ));
            return 0
        ;;
        -jpeg)
            COMPREPLY=($( compgen -W 'noprogressive progressive nobaseline \
                baseline optimize= smooth= quality= outdir=' -- "$cur" ));
            return 0
        ;;
        -xvidopts)
            COMPREPLY=($( compgen -W 'dr2 nodr2' -- "$cur" ));
            return 0
        ;;
        -xvidencopts)
            COMPREPLY=($( compgen -W 'pass= bitrate= fixed_quant= me_quality= \
                4mv rc_reaction_delay_factor= rc_averaging_period= rc_buffer= \
                quant_range= min_key_interval= max_key_interval= mpeg_quant \
                mod_quant lumi_mask hintedme hintfile debug keyframe_boost= \
                kfthreshold= kfreduction=' -- "$cur" ));
            return 0
        ;;
        -divx4opts)
            COMPREPLY=($( compgen -W 'br= key= deinterlace q= min_quant= \
                max_quant= rc_period= rc_reaction_period= crispness= \
                rc_reaction_ratio= pass= vbrpass= help' -- "$cur" ));
            return 0
        ;;
        -info)
            COMPREPLY=($( compgen -W 'name= artist= genre= subject= \
                copyright= srcform= comment= help' -- "$cur" ));
            return 0
        ;;
        -lameopts)
            COMPREPLY=($( compgen -W 'vbr= abr cbr br= q= aq= ratio= vol= \
                mode= padding= fast preset= help' -- "$cur" ));
            return 0
        ;;
        -rawaudio)
            COMPREPLY=($( compgen -W 'on channels= rate= samplesize= format='                 -- "$cur" ));
            return 0
        ;;
        -rawvideo)
            COMPREPLY=($( compgen -W 'on fps= sqcif qcif cif 4cif pal ntsc w= \
                h= y420 yv12 yuy2 y8 format= size=' -- "$cur" ));
            return 0
        ;;
        -aop)
            COMPREPLY=($( compgen -W 'list= delay= format= fout= volume= mul= \
                softclip' -- "$cur" ));
            return 0
        ;;
        -dxr2)
            COMPREPLY=($( compgen -W 'ar-mode= iec958-encoded iec958-decoded \
                mute ucode= 75ire bw color interlaced macrovision= norm= \
                square-pixel ccir601-pixel cr-left= cr-right= cr-top= cr-bot= \
                ck-rmin= ck-gmin= ck-bmin= ck-rmax= ck-gmax= ck-bmax= ck-r= \
                ck-g= ck-b= ignore-cache= ol-osd= olh-cor= olw-cor= olx-cor= \
                oly-cor= overlay overlay-ratio= update-cache' -- "$cur" ));
            return 0
        ;;
        -tv)
            COMPREPLY=($( compgen -W 'on noaudio driver= device= input= freq= \
                outfmt= width= height= buffersize= norm= channel= chanlist= \
                audiorate= forceaudio alsa amode= forcechan= adevice= audioid= \
                volume= bass= treble= balance= fps= channels= immediatemode='                 -- "$cur" ));
            return 0
        ;;
        -mf)
            COMPREPLY=($( compgen -W 'on w= h= fps= type=' -- "$cur" ));
            return 0
        ;;
        -cdda)
            COMPREPLY=($( compgen -W 'speed= paranoia= generic-dev= \
                sector-size= overlap= toc-bias toc-offset= skip noskip' \ 
                -- "$cur" ));
            return 0
        ;;
        -input)
            COMPREPLY=($( compgen -W 'conf= ar-delay ar-rate keylist cmdlist \
                js-dev file' -- "$cur" ));
            return 0
        ;;
        -af)
            COMPREPLY=($( compgen -W 'resample resample= channels channels= \
                format format= volume volume= delay delay= pan pan= sub sub= \
                surround surround=' -- "$cur" ));
            return 0
        ;;
        -af-adv)
            COMPREPLY=($( compgen -W 'force= list=' -- "$cur" ));
            return 0
        ;;
    esac;
    case "$cur" in 
        -*)
            COMPREPLY=($( compgen -W '$( $cmd -list-options 2>/dev/null | \
                sed -ne '1,/^[[:space:]]*Name/d' \
                    -e "s/^[[:space:]]*/-/" -e "s/[[:space:]:].*//" \
                    -e "/^-\(Total\|.*\*\)\?$/!p" )' -- "$cur" ))
        ;;
        *)
            _filedir '@(mp?(e)g|MP?(E)G|wm[av]|WM[AV]|avi|AVI|asf|ASF|vob|VOB|bin|BIN|dat|DAT|vcd|VCD|ps|PS|pes|PES|fl[iv]|FL[IV]|viv|VIV|rm?(j)|RM?(J)|ra?(m)|RA?(M)|yuv|YUV|mov|MOV|qt|QT|mp[234]|MP[234]|m4[av]|M4[AV]|og[gmavx]|OG[GMAVX]|w?(a)v|W?(A)V|dump|DUMP|mk[av]|MK[AV]|m4a|M4A|aac|AAC|m[24]v|M[24]V|dv|DV|rmvb|RMVB|mid|MID|ts|TS|3g[p2]|mpc|MPC|flac|FLAC|vro|VRO|divx|DIVX|aif?(f)|AIF?(F)|m2ts|M2TS|vdr|VDR|xvid|XVID|ape|APE)'
        ;;
    esac;
    return 0
}
_mplayer_options_list () 
{ 
    cur=${cur%\\};
    COMPREPLY=($( compgen -W "$( $1 $2 help 2>/dev/null |         sed -e '1,/^Available/d' | awk '{print $1}' |         sed -e 's/:$//' -e 's/^'${2#-}'$//' -e 's/<.*//' )" -- "$cur" ))
}
_msg_opts () 
{ 
    local arg pkgs pkgname msgname searchmsg path count opts;
    if [[ $1 =~ .+/.* ]]; then
        pkgname=${1%%/*};
        msgname=${1#*/};
        searchmsg=1;
    else
        pkgname=${1};
    fi;
    if [[ -z ${searchmsg} ]]; then
        pkgs=(`rospack list | grep "^${pkgname}"`);
        count=0;
        opts="";
        for ((i = 0 ; i < ${#pkgs[@]} ; i=i+2 ))
        do
            if [[ -d ${pkgs[i+1]}/msg ]]; then
                opts="$opts ${pkgs[i]}/";
                pkgname=${pkgs[i]};
                count=$((count+1));
            fi;
        done;
        if [[ $count -gt 1 ]]; then
            echo $opts;
            return 0;
        fi;
    fi;
    path=`rospack find ${pkgname} 2> /dev/null`;
    if [ $? -eq 0 ] && [ -d ${path}/msg ]; then
        echo `find -L ${path}/msg -maxdepth 1 -mindepth 1 -name *.msg ! -regex ".*/[.].*" -print0 | tr '\000' '\n' | sed -e "s/.*\/\(.*\)\.msg/${pkgname}\/\1/g"`;
    fi
}
_newgrp () 
{ 
    COMPREPLY=();
    if [[ "`_get_cword`" == "-" ]]; then
        COMPREPLY=(-);
    fi
}
_newusers () 
{ 
    local cur prev split=false;
    COMPREPLY=();
    cur=`_get_cword`;
    prev=${COMP_WORDS[COMP_CWORD-1]};
    _split_longopt && split=true;
    case "$prev" in 
        -c | --crypt)
            COMPREPLY=($( compgen -W 'DES MD5 NONE SHA256 SHA512'                 -- "$cur" ));
            return 0
        ;;
        -s | --sha-rounds)
            return 0
        ;;
    esac;
    $split && return 0;
    if [[ "$cur" == -* ]]; then
        COMPREPLY=($( compgen -W '-c --crypt-method --r --system \
            -s --sha-rounds' -- "$cur" ));
        return 0;
    fi;
    _filedir
}
_nslookup () 
{ 
    local cur;
    COMPREPLY=();
    cur=${COMP_WORDS[COMP_CWORD]#-};
    COMPREPLY=($( compgen -P '-' -W 'all class= debug d2 domain= srchlist= \
        defname search port= querytype= type= recurse retry root timeout vc \
        ignoretc' -- "$cur" ))
}
_ntpdate () 
{ 
    local cur prev;
    COMPREPLY=();
    cur=`_get_cword`;
    prev=${COMP_WORDS[COMP_CWORD-1]};
    case $prev in 
        -k)
            _filedir;
            return 0
        ;;
        -U)
            COMPREPLY=($( compgen -u "$cur"  ));
            return 0
        ;;
    esac;
    if [[ "$cur" == -* ]]; then
        COMPREPLY=($( compgen -W '-4 -6 -b -B -d -Q -q -s -u -v -a\
            -e -k -p -o -r -t' -- "$cur" ));
    else
        _known_hosts_real "$cur";
    fi
}
_ooexp_ () 
{ 
    local c=${COMP_WORDS[COMP_CWORD]};
    local a="${COMP_LINE}";
    local e s g=0 cd dc t="";
    local IFS;
    shopt -q extglob && g=1;
    test $g -eq 0 && shopt -s extglob;
    cd='*-?(c)d*';
    dc='*-d?(c)*';
    case "${1##*/}" in 
        oobase)
            e='!*.+(odb|ODB)'
        ;;
        oofromtemplate)
            e='!*.+(stw|STW|dot|DOT|vor|VOR|stc|STC|xlt|XLT|sti|STI|pot|POT|std|STD|stw|STW|dotm|DOTM|dotx|DOTX|potm|POTM|potx|POTX|xltm|XLTM|xltx|XLTX)'
        ;;
        oodraw)
            e='!*.+(sxd|SXD|std|STD|dxf|DXF|emf|EMF|eps|EPS|met|MET|pct|PCT|sgf|SGF|sgv|SGV|sda|SDA|sdd|SDD|vor|VOR|svm|SVM|wmf|WMF|bmp|BMP|gif|GIF|jpg|JPG|jpeg|JPEG|jfif|JFIF|fif|FIF|jpe|JPE|pcd|PCD|pcx|PCX|pgm|PGM|png|PNG|ppm|PPM|psd|PSD|ras|RAS|tga|TGA|tif|TIF|tiff|TIFF|xbm|XBM|xpm|XPM|odg|ODG|otg|OTG|fodg|FODG|odc|ODC|odi|ODI|sds|SDS|wpg|WPG|svg|SVG)'
        ;;
        oocalc)
            e='!*.+(sxc|SXC|stc|STC|dif|DIF|dbf|DBF|xls|XLS|xlw|XLW|xlt|XLT|rtf|RTF|sdc|SDC|vor|VOR|slk|SLK|txt|TXT|htm|HTM|html|HTML|wk1|WK1|wks|WKS|123|123|xml|XML|ods|ODS|ots|OTS|fods|FODS|csv|CSV|xlsb|XLSB|xlsm|XLSM|xlsx|XLSX|xltm|XLTM|xltx|XLTX)'
        ;;
        oomath)
            e='!*.+(sxm|SXM|smf|SMF|mml|MML|odf|ODF)'
        ;;
        ooweb)
            e='!*.+(htm|HTM|html|HTML|stw|STW|txt|TXT|vor|VOR|oth|OTH)'
        ;;
        ooffice)
            e='!*.+(sxd|SXD|std|STD|dxf|DXF|emf|EMF|eps|EPS|met|MET|pct|PCT|sgf|SGF|sgv|SGV|sda|SDA|sdd|SDD|vor|VOR|svm|SVM|wmf|WMF|bmp|BMP|gif|GIF|jpg|JPG|jpeg|JPEG|jfif|JFIF|fif|FIF|jpe|JPE|pcd|PCD|pcx|PCX|pgm|PGM|png|PNG|ppm|PPM|psd|PSD|ras|RAS|tga|TGA|tif|TIF|tiff|TIFF|xbm|XBM|xpm|XPM|odg|ODG|otg|OTG|fodg|FODG|odc|ODC|odi|ODI|sds|SDS|wpg|WPG|svg|SVG|doc|DOC|dot|DOT|rtf|RTF|sxw|SXW|stw|STW|sdw|SDW|vor|VOR|txt|TXT|htm?|HTM?|xml|XML|wp|WP|wpd|WPD|wps|WPS|odt|ODT|ott|OTT|fodt|FODT|docm|DOCM|docx|DOCX|dotm|DOTM|dotx|DOTX|sxm|SXM|smf|SMF|mml|MML|odf|ODF|sxi|SXI|sti|STI|ppt|PPT|pps|PPS|pot|POT|sxd|SXD|sda|SDA|sdd|SDD|sdp|SDP|vor|VOR|cgm|CGM|odp|ODP|otp|OTP|fodp|FODP|ppsm|PPSM|ppsx|PPSX|pptm|PPTM|pptx|PPTX|potm|POTM|potx|POTX|odb|ODB|sxc|SXC|stc|STC|dif|DIF|dbf|DBF|xls|XLS|xlw|XLW|xlt|XLT|rtf|RTF|sdc|SDC|vor|VOR|slk|SLK|txt|TXT|htm|HTM|html|HTML|wk1|WK1|wks|WKS|123|123|xml|XML|ods|ODS|ots|OTS|fods|FODS|csv|CSV|xlsb|XLSB|xlsm|XLSM|xlsx|XLSX|xltm|XLTM|xltx|XLTX|sxg|SXG|odm|ODM|sgl|SGL|stw|STW|dot|DOT|vor|VOR|stc|STC|xlt|XLT|sti|STI|pot|POT|std|STD|stw|STW|dotm|DOTM|dotx|DOTX|potm|POTM|potx|POTX|xltm|XLTM|xltx|XLTX|htm|HTM|html|HTML|stw|STW|txt|TXT|vor|VOR|oth|OTH)'
        ;;
        oowriter)
            e='!*.+(doc|DOC|dot|DOT|rtf|RTF|sxw|SXW|stw|STW|sdw|SDW|vor|VOR|txt|TXT|htm?|HTM?|xml|XML|wp|WP|wpd|WPD|wps|WPS|odt|ODT|ott|OTT|fodt|FODT|docm|DOCM|docx|DOCX|dotm|DOTM|dotx|DOTX|sxg|SXG|odm|ODM|sgl|SGL)'
        ;;
        ooimpress)
            e='!*.+(sxi|SXI|sti|STI|ppt|PPT|pps|PPS|pot|POT|sxd|SXD|sda|SDA|sdd|SDD|sdp|SDP|vor|VOR|cgm|CGM|odp|ODP|otp|OTP|fodp|FODP|ppsm|PPSM|ppsx|PPSX|pptm|PPTM|pptx|PPTX|potm|POTM|potx|POTX)'
        ;;
        unopkg)
            e='!*.+(oxt|OXT)'
        ;;
        *)
            e='!*'
        ;;
    esac;
    case "$(complete -p ${1##*/} 2> /dev/null)" in 
        *-d*)

        ;;
        *)
            s="-S/"
        ;;
    esac;
    IFS='
';
    case "$c" in 
        \$\(*\))
            eval COMPREPLY=\(${c}\)
        ;;
        \$\(*)
            COMPREPLY=($(compgen -c -P '$(' -S ')'  -- ${c#??}))
        ;;
        \`*\`)
            eval COMPREPLY=\(${c}\)
        ;;
        \`*)
            COMPREPLY=($(compgen -c -P '\`' -S '\`' -- ${c#?}))
        ;;
        \$\{*\})
            eval COMPREPLY=\(${c}\)
        ;;
        \$\{*)
            COMPREPLY=($(compgen -v -P '${' -S '}'  -- ${c#??}))
        ;;
        \$*)
            COMPREPLY=($(compgen -v -P '$'          -- ${c#?}))
        ;;
        \~*/*)
            COMPREPLY=($(compgen -f -X "$e"         -- ${c}))
        ;;
        \~*)
            COMPREPLY=($(compgen -u ${s}	 	-- ${c}))
        ;;
        *@*)
            COMPREPLY=($(compgen -A hostname -P '@' -S ':' -- ${c#*@}))
        ;;
        *[*?[]*)
            COMPREPLY=($(compgen -G "${c}"))
        ;;
        *[?*+\!@]\(*\)*)
            if test $g -eq 0; then
                COMPREPLY=($(compgen -f -X "$e" -- $c));
                test $g -eq 0 && shopt -u extglob;
                return;
            fi;
            COMPREPLY=($(compgen -G "${c}"))
        ;;
        *)
            if test "$c" = ".."; then
                COMPREPLY=($(compgen -d -X "$e" -S / ${_nosp} -- $c));
            else
                for s in $(compgen -f -X "$e" -- $c);
                do
                    if test -d $s; then
                        COMPREPLY=(${COMPREPLY[@]} $(compgen -f -X "$e" -S / -- $s));
                    else
                        if test -z "$t"; then
                            COMPREPLY=(${COMPREPLY[@]} $s);
                        else
                            case "$(file -b $s 2> /dev/null)" in 
                                $t)
                                    COMPREPLY=(${COMPREPLY[@]} $s)
                                ;;
                            esac;
                        fi;
                    fi;
                done;
            fi
        ;;
    esac;
    test $g -eq 0 && shopt -u extglob
}
_openssl () 
{ 
    local cur prev commands command options formats;
    COMPREPLY=();
    cur=`_get_cword`;
    commands='asn1parse ca ciphers crl crl2pkcs7 dgst dh dhparam dsa \
        dsaparam ec ecparam enc engine errstr gendh gendsa genrsa \
        nseq ocsp passwd pkcs12 pkcs7 pkcs8 prime rand req rsa \
        rsautl s_client s_server s_time sess_id smime speed spkac \
        verify version x509 md2 md4 md5 rmd160 sha sha1 aes-128-cbc \
        aes-128-ecb aes-192-cbc aes-192-ecb aes-256-cbc aes-256-ecb \
        base64 bf bf-cbc bf-cfb bf-ecb bf-ofb camellia-128-cbc \
        camellia-128-ecb camellia-192-cbc camellia-192-ecb \
        camellia-256-cbc camellia-256-ecb cast cast-cbc cast5-cbc \
        cast5-cfb cast5-ecb cast5-ofb des des-cbc des-cfb des-ecb \
        des-ede des-ede-cbc des-ede-cfb des-ede-ofb des-ede3 \
        des-ede3-cbc des-ede3-cfb des-ede3-ofb des-ofb des3 desx rc2 \
        rc2-40-cbc rc2-64-cbc rc2-cbc rc2-cfb rc2-ecb rc2-ofb rc4 \
        rc4-40';
    if [ $COMP_CWORD -eq 1 ]; then
        COMPREPLY=($( compgen -W "$commands" -- "$cur" ));
    else
        command=${COMP_WORDS[1]};
        prev=${COMP_WORDS[COMP_CWORD-1]};
        case $prev in 
            -@(CA|CAfile|CAkey|CAserial|cert|certfile|config|content|dcert|dkey|dhparam|extfile|in|inkey|kfile|key|keyout|out|oid|prvrify|rand|recip|revoke|sess_in|sess_out|spkac|sign|signkey|signer|signature|ss_cert|untrusted|verify))
                _filedir;
                return 0
            ;;
            -@(outdir|CApath))
                _filedir -d;
                return 0
            ;;
            -@(name|crlexts|extensions))
                _openssl_sections;
                return 0
            ;;
            -@(in|out|key|cert|CA|CAkey|dkey|dcert)form)
                formats='DER PEM';
                case $command in 
                    x509)
                        formats="$formats NET"
                    ;;
                    smime)
                        formats="$formats SMIME"
                    ;;
                esac;
                COMPREPLY=($( compgen -W "$formats" -- "$cur" ));
                return 0
            ;;
            -connect)
                _known_hosts_real "$cur";
                return 0
            ;;
            -starttls)
                COMPREPLY=($( compgen -W 'smtp pop3 imap ftp'                     -- "$cur" ));
                return 0
            ;;
            -cipher)
                COMPREPLY=($( compgen -W "$(openssl ciphers |                     tr ':' '\n')" -- "$cur" ));
                return 0
            ;;
        esac;
        if [[ "$cur" == -* ]]; then
            case $command in 
                asn1parse)
                    options='-inform -in -out -noout -offset -length -i -oid \
                        -strparse'
                ;;
                ca)
                    options='-verbose -config -name -gencrl -revoke \
                        -crl_reason -crl_hold -crl_compromise \
                        -crl_CA_compromise -crldays -crlhours -crlexts \
                        -startdate -enddate -days -md -policy -keyfile -key \
                        -passin -cert -selfsig -in -out -notext -outdir \
                        -infiles -spkac -ss_cert -preserveDN -noemailDN \
                        -batch -msie_hack -extensions -extfile -engine \
                        -subj -utf8 -multivalue-rdn'
                ;;
                ciphers)
                    options='-v -ssl2 -ssl3 -tls1'
                ;;
                crl)
                    options='-inform -outform -text -in -out -noout -hash \
                        -issuer -lastupdate -nextupdate -CAfile -CApath'
                ;;
                crl2pkcs7)
                    options='-inform -outform -in -out -print_certs'
                ;;
                dgst)
                    options='-md5 -md4 -md2 -sha1 -sha -mdc2 -ripemd160 -dss1 \
                        -c -d -hex -binary -out -sign -verify -prverify \
                        -signature'
                ;;
                dsa)
                    options='-inform -outform -in -passin -out -passout -des \
                        -des3 -idea -text -noout -modulus -pubin -pubout'
                ;;
                dsaparam)
                    options='-inform -outform -in -out -noout -text -C -rand \
                        -genkey'
                ;;
                enc)
                    options='-ciphername -in -out -pass -e -d -a -A -k -kfile \
                        -S -K -iv -p -P -bufsize -debug'
                ;;
                dhparam)
                    options='-inform -outform -in -out -dsaparam -noout -text \
                        -C -2 -5 -rand'
                ;;
                gendsa)
                    options='-out -des -des3 -idea -rand'
                ;;
                genrsa)
                    options='-out -passout -des -des3 -idea -f4 -3 -rand'
                ;;
                pkcs7)
                    options='-inform -outform -in -out -print_certs -text \
                        -noout'
                ;;
                rand)
                    options='-out -rand -base64'
                ;;
                req)
                    options='-inform -outform -in -passin -out -passout -text \
                        -noout -verify -modulus -new -rand -newkey -newkey \
                        -nodes -key -keyform -keyout -md5 -sha1 -md2 -mdc2 \
                        -config -x509 -days -asn1-kludge -newhdr -extensions \
                        -reqexts section'
                ;;
                rsa)
                    options='-inform -outform -in -passin -out -passout \
                        -sgckey -des -des3 -idea -text -noout -modulus -check \
                        -pubin -pubout -engine'
                ;;
                rsautl)
                    options='-in -out -inkey -pubin -certin -sign -verify \
                        -encrypt -decrypt -pkcs -ssl -raw -hexdump -asn1parse'
                ;;
                s_client)
                    options='-connect -verify -cert -certform -key -keyform \
                        -pass -CApath -CAfile -reconnect -pause -showcerts \
                        -debug -msg -nbio_test -state -nbio -crlf -ign_eof \
                        -quiet -ssl2 -ssl3 -tls1 -no_ssl2 -no_ssl3 -no_tls1 \
                        -bugs -cipher -starttls -engine -tlsextdebug \
                        -no_ticket -sess_out -sess_in -rand'
                ;;
                s_server)
                    options='-accept -context -verify -Verify -crl_check \
                        -crl_check_all -cert -certform -key -keyform -pass \
                        -dcert -dcertform -dkey -dkeyform -dpass -dhparam \
                        -nbio -nbio_test -crlf -debug -msg -state -CApath \
                        -CAfile -nocert -cipher -quiet -no_tmp_rsa -ssl2 \
                        -ssl3 -tls1 -no_ssl2 -no_ssl3 -no_tls1 -no_dhe \
                        -bugs -hack -www -WWW -HTTP -engine -tlsextdebug \
                        -no_ticket -id_prefix -rand'
                ;;
                s_time)
                    options='-connect -www -cert -key -CApath -CAfile -reuse \
                        -new -verify -nbio -time -ssl2 -ssl3 -bugs -cipher'
                ;;
                sess_id)
                    options='-inform -outform -in -out -text -noout -context \
                        ID'
                ;;
                smime)
                    options='-encrypt -decrypt -sign -verify -pk7out -des \
                        -des3 -rc2-40 -rc2-64 -rc2-128 -aes128 -aes192 -aes256 \
                        -in -certfile -signer -recip -inform -passin -inkey \
                        -out -outform -content -to -from -subject -text -rand'
                ;;
                speed)
                    options='-engine'
                ;;
                verify)
                    options='-CApath -CAfile -purpose -untrusted -help \
                        -issuer_checks -verbose -certificates'
                ;;
                x509)
                    options='-inform -outform -keyform -CAform -CAkeyform -in \
                        -out -serial -hash -subject-hash -issuer_hash -subject \
                        -issuer -nameopt -email -startdate -enddate -purpose \
                        -dates -modulus -fingerprint -alias -noout -trustout \
                        -clrtrust -clrreject -addtrust -addreject -setalias \
                        -days -set_serial -signkey -x509toreq -req -CA -CAkey \
                        -CAcreateserial -CAserial -text -C -md2 -md5 -sha1 \
                        -mdc2 -clrext -extfile -extensions -engine'
                ;;
                @(md5|md4|md2|sha1|sha|mdc2|ripemd160))
                    options='-c -d'
                ;;
            esac;
            COMPREPLY=($( compgen -W "$options" -- "$cur" ));
        else
            if [[ "$command" == speed ]]; then
                COMPREPLY=($( compgen -W 'md2 mdc2 md5 hmac sha1 rmd160 \
                    idea-cbc rc2-cbc rc5-cbc bf-cbc des-cbc des-ede3 rc4 \
                    rsa512 rsa1024 rsa2048 rsa4096 dsa512 dsa1024 dsa2048 idea \
                    rc2 des rsa blowfish' -- "$cur" ));
            else
                _filedir;
            fi;
        fi;
    fi
}
_openssl_sections () 
{ 
    local config f;
    for ((i=2; i < COMP_CWORD; i++ ))
    do
        if [[ "${COMP_WORDS[i]}" == -config ]]; then
            config=${COMP_WORDS[i+1]};
            break;
        fi;
    done;
    if [ -z "$config" ]; then
        for f in /etc/ssl/openssl.cnf /etc/pki/tls/openssl.cnf /usr/share/ssl/openssl.cnf;
        do
            [ -f $f ] && config=$f && break;
        done;
    fi;
    [ ! -f "$config" ] && return 0;
    COMPREPLY=($( compgen -W "$( awk '/\[.*\]/ {print $2}' $config )"         -- "$cur" ))
}
_parse_help () 
{ 
    local cmd;
    cmd=$1;
    $cmd --help | grep --color=auto -- "^[[:space:]]*-" | tr "," " " | awk '{print $1; if ($2 ~ /-.*/) { print $2 } }' | sed -e "s:=.*::g"
}
_passwd () 
{ 
    local cur prev;
    COMPREPLY=();
    cur=`_get_cword`;
    prev=${COMP_WORDS[COMP_CWORD-1]};
    case "$prev" in 
        -n | -x | -w | -i | -\? | --help | --usage)
            return 0
        ;;
    esac;
    if [[ "$cur" == -* ]]; then
        COMPREPLY=($( compgen -W '-k -l --stdin -u -d -n -x -w -i -S \
            -? --help --usage' -- "$cur" ));
        return 0;
    fi;
    COMPREPLY=($( compgen -u -- "$cur" ))
}
_pci_ids () 
{ 
    COMPREPLY=(${COMPREPLY[@]:-} $( compgen -W     "$( PATH="$PATH:/sbin" lspci -n | awk '{print $3}')" -- "$cur" ))
}
_perl () 
{ 
    local cur prev prefix temp;
    local optPrefix optSuffix;
    COMPREPLY=();
    cur=`_get_cword`;
    prev=${COMP_WORDS[COMP_CWORD-1]};
    prefix="";
    if [[ "$cur" == -?* ]]; then
        temp=$cur;
        prev=${temp:0:2};
        cur=${temp:2};
        optPrefix=-P$prev;
        optSuffix=-S/;
        prefix=$prev;
    fi;
    case "$prev" in 
        -I | -x)
            local IFS='	
';
            COMPREPLY=($( compgen -d $optPrefix $optSuffix -- "$cur" ));
            return 0
        ;;
        -m | -M)
            _perlmodules;
            return 0
        ;;
    esac;
    if [[ "$cur" == -* ]]; then
        COMPREPLY=($( compgen -W '-C -s -T -u -U -W -X -h -v -V -c -w -d \
		    -D -p -n -a -F -l -0 -I -m -M -P -S -x -i -e ' -- "$cur" ));
    else
        _filedir;
    fi
}
_perldoc () 
{ 
    local cur prev prefix temp;
    COMPREPLY=();
    cur=`_get_cword`;
    prev=${COMP_WORDS[COMP_CWORD-1]};
    prefix="";
    if [[ "$cur" == -?* ]]; then
        temp=$cur;
        prev=${temp:0:2};
        cur=${temp:2};
        prefix=$prev;
    fi;
    case $prev in 
        -f)
            COMPREPLY=($( compgen -W 'chomp chop chr crypt hex index lc \
                lcfirst length oct ord pack q qq reverse rindex sprintf \
                substr tr uc ucfirst y m pos quotemeta s split study qr abs \
                atan2 cos exp hex int log oct rand sin sqrt srand pop push \
                shift splice unshift grep join map qw reverse sort unpack \
                delete each exists keys values binmode close closedir \
                dbmclose dbmopen die eof fileno flock format getc print \
                printf read readdir rewinddir seek seekdir select syscall \
                sysread sysseek syswrite tell telldir truncate warn write \
                pack read syscall sysread syswrite unpack vec -X chdir chmod \
                chown chroot fcntl glob ioctl link lstat mkdir open opendir \
                readlink rename rmdir stat symlink umask unlink utime caller \
                continue do dump eval exit goto last next redo return \
                sub wantarray caller import local my our package use defined \
                formline reset scalar undef \
                alarm exec fork getpgrp getppid getpriority kill pipe qx \
                setpgrp setpriority sleep system times wait waitpid \
                import no package require use bless dbmclose dbmopen package \
                ref tie tied untie use accept bind connect getpeername \
                getsockname getsockopt listen recv send setsockopt shutdown \
                socket socketpair msgctl msgget msgrcv msgsnd semctl semget \
                semop shmctl shmget shmread shmwrite endgrent endhostent \
                endnetent endpwent getgrent getgrgid getgrnam getlogin \
                getpwent getpwnam getpwuid setgrent setpwent endprotoent \
                endservent gethostbyaddr gethostbyname gethostent \
                getnetbyaddr getnetbyname getnetent getprotobyname \
                getprotobynumber getprotoent getservbyname getservbyport \
                getservent sethostent setnetent setprotoent setservent \
                gmtime localtime time times' -- "$cur" ));
            return 0
        ;;
    esac;
    if [[ "$cur" == -* ]]; then
        COMPREPLY=($( compgen -W '-h -v -t -u -m -l -F -X -f -q' -- "$cur" ));
    else
        if [[ "$cur" != */* ]]; then
            _perlmodules;
            COMPREPLY=("${COMPREPLY[@]}" $( compgen -W                 '$( PAGER=/bin/cat man perl |  \
                sed -ne "/perl.*Perl overview/,/perlwin32/p" | \
                awk "\$NF=2 { print \$1}" | grep perl )' -- "$cur" ));
        fi;
    fi
}
_perlmodules () 
{ 
    COMPREPLY=($( compgen -P "$prefix" -W "$( perl -e 'sub mods { my ($base,$dir)=@_; return if  $base !~ /^\Q$ENV{cur}/; chdir($dir) or return; for (glob(q[*.pm])) {s/\.pm$//; print qq[$base$_\n]}; mods(/^(?:[.\d]+|$Config{archname}-$Config{osname}|auto)$/ ? undef : qq[${base}${_}\\\\:\\\\:],qq[$dir/$_]) for grep {-d} glob(q[*]); } mods(undef,$_) for @INC;' )" -- "$cur" ))
}
_pg_databases () 
{ 
    return;
    COMPREPLY=($( compgen -W "$( psql -l 2>/dev/null |         sed -e '1,/^-/d' -e '/^(/,$d' |         awk '{print $1}' )" -- "$cur" ))
}
_pg_users () 
{ 
    COMPREPLY=($( compgen -u -- "$cur" ))
}
_pgids () 
{ 
    COMPREPLY=($( compgen -W '$( command ps axo pgid= )' -- "$cur" ))
}
_pgrep () 
{ 
    local cur;
    COMPREPLY=();
    cur=`_get_cword`;
    _pnames;
    return 0
}
_pids () 
{ 
    COMPREPLY=($( compgen -W '$( command ps axo pid= )' -- "$cur" ))
}
_pkcon () 
{ 
    local i c=1 command;
    while [ $c -lt $COMP_CWORD ]; do
        i="${COMP_WORDS[c]}";
        case "$i" in 
            --version | --help | --verbose | --nowait | -v | -n | -h | -?)

            ;;
            *)
                command="$i";
                break
            ;;
        esac;
        c=$((++c));
    done;
    if [ $c -eq $COMP_CWORD -a -z "$command" ]; then
        case "${COMP_WORDS[COMP_CWORD]}" in 
            --*=*)
                COMPREPLY=()
            ;;
            --*)
                __pkconcomp "
			--version
			--filter
			--verbose
            --help
            --nowait
			"
            ;;
            -*)
                __pkconcomp "
            -v
            -n
            -h
            -?
			--version
			--verbose
            --help
            --filter
            --nowait
            "
            ;;
            *)
                __pkconcomp "$__pkcon_commandlist"
            ;;
        esac;
        return;
    fi;
    case "$command" in 
        search)
            _pkcon_search
        ;;
        *)
            COMPREPLY=()
        ;;
    esac
}
_pkcon_search () 
{ 
    local i c=1 command;
    while [ $c -lt $COMP_CWORD ]; do
        i="${COMP_WORDS[c]}";
        case "$i" in 
            name | details | group | file)
                command="$i";
                break
            ;;
        esac;
        c=$((++c));
    done;
    if [ $c -eq $COMP_CWORD -a -z "$command" ]; then
        __pkconcomp "name details group file";
    fi;
    return
}
_pkg_config () 
{ 
    local cur prev split=false;
    COMPREPLY=();
    cur=`_get_cword`;
    prev=${COMP_WORDS[COMP_CWORD-1]};
    _split_longopt && split=true;
    case $prev in 
        --@(?(define-)variable|@(atleast?(-pkgconfig)|exact|max)-version))
            return 0
        ;;
        -\? | --help | --version | --usage)
            return 0
        ;;
    esac;
    $split && return 0;
    if [[ "$cur" == -* ]]; then
        COMPREPLY=($( compgen -W '--version --modversion \
            --atleast-pkgconfig-version --libs --static \
            --short-errors --libs-only-l --libs-only-other \
            --libs-only-L --cflags --cflags-only-I \
            --cflags-only-other --variable --define-variable \
            --exists --uninstalled --atleast-version \
            --exact-version --max-version --list-all --debug \
            --print-errors --silence-errors --errors-to-stdout \
            --print-provides --print-requires -? --help --usage'             -- "$cur"));
    else
        COMPREPLY=($( compgen -W "$( pkg-config --list-all             2>/dev/null | awk '{print $1}' )" -- "$cur" ));
    fi
}
_pnames () 
{ 
    COMPREPLY=($( compgen -W '$( command ps axo command= | \
    sed -e "s/ .*//; s:.*/::; s/:$//;" \
    -e "s/^[[(-]//; s/[])]$//" \
    -e "s/^<defunct>$//")'     -- "$cur" ))
}
_poff () 
{ 
    local prev cur conns;
    [ -r /etc/ppp/peers/ ] || return 0;
    COMPREPLY=();
    prev=${COMP_WORDS[COMP_CWORD-1]};
    cur=${COMP_WORDS[COMP_CWORD]};
    conns=$(\ls --color=none /etc/ppp/peers | egrep -v '(\.bak|~)$');
    if [[ "$cur" == -* ]]; then
        COMPREPLY=($(compgen -W '-r -d -c -a -h -v' -- $cur));
        return 0;
    fi;
    if [ $COMP_CWORD -eq 1 ] && [[ "$cur" != -* ]] || [[ "$prev" == -* ]]; then
        COMPREPLY=($(compgen -o filenames -W "$conns" $cur));
    fi;
    return 0
}
_pon () 
{ 
    local cur conns;
    [ -r /etc/ppp/peers/ ] || return 0;
    COMPREPLY=();
    cur=${COMP_WORDS[COMP_CWORD]};
    conns=$(\ls --color=none /etc/ppp/peers | egrep -v '(\.bak|~)$');
    if [ $COMP_CWORD -eq 1 ]; then
        COMPREPLY=($(compgen -o filenames -W "$conns" $cur));
    fi;
    return 0
}
_psql () 
{ 
    local cur prev split=false;
    COMPREPLY=();
    cur=`_get_cword`;
    prev=${COMP_WORDS[COMP_CWORD-1]};
    _split_longopt && split=true;
    case "$prev" in 
        -h | --host)
            _known_hosts_real "$cur";
            return 0
        ;;
        -U | --username)
            _pg_users;
            return 0
        ;;
        -d | --dbname)
            _pg_databases;
            return 0
        ;;
        -o | --output | -f | --file | -L | --log-file)
            _filedir;
            return 0
        ;;
        -c | --command | -F | --field-separator | -p | --port | -P | --pset | -R | --record-separator | -T | --table-attr | -v | --set | --variable)
            return 0
        ;;
        -\? | --help | -V | --version)
            return 0
        ;;
    esac;
    $split && return 0;
    if [[ "$cur" == -* ]]; then
        COMPREPLY=($( compgen -W '-a --echo-all -A --no-align \
            -c --command -d --dbname -e --echo-queries \
            -E --echo-hidden -f --file -F --field-separator \
            -h --host -H --html -l --list -L --log-file -n \
            -o --output -p --port -P --pset -q --quiet \
            -R --record-separator -s --single-step \
            -S --single-line -t --tuples-only -T --table-attr \
            -U --username -v --set --variable -V --version \
            -W --password -x --expanded -X --no-psqlrc \
            -1 --single-transaction -? --help' -- "$cur" ));
    else
        _pg_databases;
    fi
}
_pwck () 
{ 
    local cur;
    COMPREPLY=();
    cur=`_get_cword`;
    if [[ "$cur" == -* ]]; then
        COMPREPLY=($( compgen -W '-q -r -s' -- "$cur" ));
        return 0;
    fi;
    _filedir
}
_python () 
{ 
    local prev cur i;
    COMPREPLY=();
    cur=`_get_cword`;
    prev=${COMP_WORDS[COMP_CWORD-1]##*/};
    case "$prev" in 
        -Q)
            COMPREPLY=($( compgen -W "old new warn warnall" -- "$cur" ));
            return 0
        ;;
        -W)
            COMPREPLY=($( compgen -W "ignore default all module once error"             -- "$cur" ));
            return 0
        ;;
        -c)
            _filedir '@(py|pyc|pyo)';
            return 0
        ;;
        !(python|-?))
            [[ ${COMP_WORDS[COMP_CWORD-2]} != -@(Q|W) ]] && _filedir
        ;;
    esac;
    for ((i=0; i < ${#COMP_WORDS[@]}-1; i++ ))
    do
        if [[ ${COMP_WORDS[i]} == -c ]]; then
            _filedir;
        fi;
    done;
    if [[ "$cur" != -* ]]; then
        _filedir '@(py|pyc|pyo)';
    else
        COMPREPLY=($( compgen -W "- -d -E -h -i -O -Q -S -t -u             -U -v -V -W -x -c" -- "$cur" ));
    fi;
    return 0
}
_qdbus () 
{ 
    local cur compstr;
    COMPREPLY=();
    cur=`_get_cword`;
    [ -n "$cur" ] && unset COMP_WORDS[${#COMP_WORDS[@]}-1];
    COMPREPLY=($( compgen -W '$( command ${COMP_WORDS[@]} | sed s/\(.*\)// )'         -- "$cur" ))
}
_rcs () 
{ 
    local cur prev file dir i;
    COMPREPLY=();
    cur=`_get_cword`;
    prev=${COMP_WORDS[COMP_CWORD-1]};
    file=${cur##*/};
    dir=${cur%/*};
    [ "$file" = "$dir" ] && dir=.;
    COMPREPLY=($( compgen -f "$dir/RCS/$file" ));
    for ((i=0; i < ${#COMPREPLY[@]}; i++ ))
    do
        file=${COMPREPLY[$i]##*/};
        dir=${COMPREPLY[$i]%RCS/*};
        COMPREPLY[$i]=$dir$file;
    done;
    COMPREPLY=("${COMPREPLY[@]}" $( compgen -G "$dir/$file*,v" ));
    for ((i=0; i < ${#COMPREPLY[@]}; i++ ))
    do
        COMPREPLY[$i]=${COMPREPLY[$i]%,v};
    done;
    [ ${#COMPREPLY[@]} -eq 0 -a $1 = ci ] && _filedir || _filedir -d
}
_rdesktop () 
{ 
    local cur prev;
    COMPREPLY=();
    cur=`_get_cword`;
    prev=${COMP_WORDS[COMP_CWORD-1]};
    case $prev in 
        -k)
            COMPREPLY=($( command ls                 /usr/share/rdesktop/keymaps 2>/dev/null |                 egrep -v '(common|modifiers)' ));
            COMPREPLY=(${COMPREPLY[@]:-} $( command ls                 $HOME/.rdesktop/keymaps 2>/dev/null ));
            COMPREPLY=(${COMPREPLY[@]:-} $( command ls                 ./keymaps 2>/dev/null ));
            COMPREPLY=($( compgen -W '${COMPREPLY[@]}' -- "$cur" ));
            return 0
        ;;
        -a)
            COMPREPLY=($( compgen -W '8 15 16 24' -- "$cur" ));
            return 0
        ;;
        -x)
            COMPREPLY=($( compgen -W 'b broadband m modem l lan'                 -- $cur ));
            return 0
        ;;
        -r)
            COMPREPLY=($( compgen -W 'comport: disk: lptport: \
                printer: sound: lspci scard' -- "$cur" ));
            return 0
        ;;
    esac;
    if [[ "$cur" == -* ]]; then
        COMPREPLY=($( compgen -W '-u -d -s -c -p -n -k -g -f -b -L \
            -A -B -e -E -m -C -D -K -S -T -N -X -a -z -x -P -r \
            -0 -4 -5' -- "$cur" ));
    else
        _known_hosts_real "$cur";
    fi
}
_realcommand () 
{ 
    type -P "$1" > /dev/null && { 
        if type -p realpath > /dev/null; then
            realpath "$(type -P "$1")";
        else
            if type -p readlink > /dev/null; then
                readlink -f "$(type -P "$1")";
            else
                type -P "$1";
            fi;
        fi
    }
}
_renice () 
{ 
    local command cur curopt i;
    COMPREPLY=();
    cur=`_get_cword`;
    command=$1;
    i=0;
    while [ $i -le $COMP_CWORD -a ${#COMPREPLY[@]} -eq 0 ]; do
        curopt=${COMP_WORDS[COMP_CWORD-$i]};
        case "$curopt" in 
            -u)
                COMPREPLY=($( compgen -u -- "$cur" ))
            ;;
            -g)
                _pgids
            ;;
            -p | $command)
                _pids
            ;;
        esac;
        i=$(( ++i ));
    done
}
_rfcomm () 
{ 
    local cur prev;
    COMPREPLY=();
    cur=`_get_cword`;
    prev=${COMP_WORDS[COMP_CWORD-1]};
    case $prev in 
        -@(f|-config))
            _filedir;
            return 0
        ;;
        -i)
            _bluetooth_devices;
            _bluetooth_adresses;
            return 0
        ;;
    esac;
    _get_command;
    if [ -z $command ]; then
        if [[ "$cur" == -* ]]; then
            COMPREPLY=($( compgen -W '-h --help -a -r --raw -f \
                --config -i -A --auth -E --encrypt -S --secure \
                -M --master' -- "$cur" ));
        else
            COMPREPLY=($( compgen -W 'show connect listen watch \
                bind release' -- "$cur" ));
        fi;
    else
        _count_args;
        if [ $args -eq 2 ]; then
            _bluetooth_devices;
        else
            case $command in 
                @(connect|bind))
                    if [ $args -eq 3 ]; then
                        _bluetooth_adresses;
                    fi
                ;;
            esac;
        fi;
    fi
}
_rfkill () 
{ 
    local cur prev;
    COMPREPLY=();
    cur=`_get_cword`;
    if [[ "$cur" == -* ]]; then
        COMPREPLY=($( compgen -W '--version' -- "$cur" ));
    else
        case $COMP_CWORD in 
            1)
                COMPREPLY=($( compgen -W "help event list block unblock"                     -- "$cur" ))
            ;;
            2)
                prev=${COMP_WORDS[COMP_CWORD-1]};
                if [ $prev == block -o $prev == unblock ]; then
                    COMPREPLY=($( compgen -W "$(rfkill list | awk -F:                         '/^[0-9]/ {print $1}') all wifi bluetooth uwb wimax                         wwan gps" -- "$cur" ));
                fi
            ;;
        esac;
    fi
}
_rl_enabled () 
{ 
    [[ "$( bind -v )" = *$1+([[:space:]])on* ]]
}
_rmmod () 
{ 
    local cur;
    COMPREPLY=();
    cur=`_get_cword`;
    _installed_modules "$cur";
    return 0
}
_root_command () 
{ 
    PATH=$PATH:/sbin:/usr/sbin:/usr/local/sbin _command $1 $2 $3
}
_ros_decode_path () 
{ 
    local rosname rosdir reldir last;
    rosvals=();
    if [[ -z $1 ]]; then
        return 0;
    fi;
    if [[ $1 =~ .+/.* ]]; then
        rosname=${1%%/*};
        reldir=/${1#*/};
        last=${reldir##*/};
        reldir=${reldir%/*}/;
    else
        rosname=$1;
        if [[ -z $2 || $2 != "forceeval" ]]; then
            rosvals=(${rosname});
            return 1;
        fi;
    fi;
    rosdir=`_ros_location_find $rosname`;
    if [[ $? != 0 ]]; then
        rosvals=(${rosname});
        return 1;
    fi;
    rosvals=(${rosname} ${rosdir} ${reldir} ${last})
}
_ros_list_locations () 
{ 
    local ROS_LOCATION_KEYS packages stacks;
    ROS_LOCATION_KEYS=`echo $ROS_LOCATIONS | _rossed -e 's/([^:=]*)=([^:=]*)(:*[^=])*(:|$)/\1 /g'`;
    packages=`export ROS_CACHE_TIMEOUT=-1.0 && rospack list-names`;
    stacks=`export ROS_CACHE_TIMEOUT=-1.0 && rosstack list-names`;
    echo $packages $stacks log test_results $ROS_LOCATION_KEYS | tr ' ' '\n';
    return 0
}
_ros_list_packages () 
{ 
    local packages;
    packages=`export ROS_CACHE_TIMEOUT=-1.0 && rospack list-names`;
    echo $packages | tr ' ' '\n';
    return 0
}
_ros_list_stacks () 
{ 
    local stacks;
    stacks=`export ROS_CACHE_TIMEOUT=-1.0 && rosstack list-names`;
    echo $stacks | tr ' ' '\n';
    return 0
}
_ros_location_find () 
{ 
    local homedir ROS_LOCATION_KEYS_ARR ROS_LOCATIONS_ARR loc;
    homedir=`echo $HOME | sed -e "s/\//\t\//g" -e "s/\t/\\\\\/g"`;
    ROS_LOCATION_KEYS_ARR=(`echo $ROS_LOCATIONS | _rossed -e 's/([^:=]*)=([^:=]*)(:*[^=])*(:|$)/\1 /g'`);
    ROS_LOCATIONS_ARR=(`echo $ROS_LOCATIONS | _rossed -e 's/([^:=]*)=([^:=]*)(:*[^=])*(:|$)/\2 /g' -e "s/~/${homedir}/g"`);
    for ((i = 0 ; i < ${#ROS_LOCATION_KEYS_ARR[@]} ; i++ ))
    do
        if [[ $1 == ${ROS_LOCATION_KEYS_ARR[$i]} ]]; then
            echo ${ROS_LOCATIONS_ARR[i]};
            return 0;
        fi;
    done;
    if [[ $1 == log ]]; then
        echo `roslaunch-logs`;
        return 0;
    else
        if [[ $1 == test_results ]]; then
            echo `rosrun rosunit test_results_dir.py`;
            return 0;
        fi;
    fi;
    loc=`export ROS_CACHE_TIMEOUT=-1.0 && rospack find $1 2> /dev/null`;
    if [[ $? != 0 ]]; then
        loc=`export ROS_CACHE_TIMEOUT=-1.0 && rosstack find $1 2> /dev/null`;
        if [[ $? != 0 ]]; then
            return 1;
        fi;
        echo $loc;
        return 0;
    fi;
    echo $loc;
    return 0
}
_ros_package_find () 
{ 
    local loc;
    loc=`export ROS_CACHE_TIMEOUT=-1.0 && rospack find $1 2> /dev/null`;
    if [[ $? != 0 ]]; then
        return 1;
    fi;
    echo $loc;
    return 0
}
_roscmd () 
{ 
    local pkgdir exepath opt catkin_source_dir catkin_binary_dir opts;
    if [[ -n $CATKIN_SOURCE_DIR ]]; then
        catkin_source_dir=`ROS_ROOT=$CATKIN_SOURCE_DIR ROS_PACKAGE_PATH= _ros_package_find $1`;
    fi;
    if [[ -n $CATKIN_BINARY_DIR && -f $CATKIN_BINARY_DIR/etc/packages.list ]]; then
        cbd=`grep $1 $CATKIN_BINARY_DIR/etc/packages.list | cut -d " " -f 2`;
        if [[ -n $cbd ]]; then
            catkin_binary_dir=$CATKIN_BINARY_DIR/$cbd;
        fi;
    fi;
    pkgdir=`_ros_package_find $1`;
    if [[ -z $catkin_source_dir && -z $catkin_binary_dir && -z $pkgdir ]]; then
        echo "Couldn't find package [$1]";
        return 1;
    fi;
    exepath=(`find -L $catkin_source_dir $catkin_binary_dir $pkgdir -name $2 -type f ! -regex .*/[.].* ! -regex .*$pkgdir\/build\/.* | uniq`);
    if [[ ${#exepath[@]} == 0 ]]; then
        echo "That file does not exist in that package.";
        return 1;
    else
        if [[ ${#exepath[@]} -gt 1 ]]; then
            echo "You have chosen a non-unique filename, please pick one of the following:";
            select opt in ${exepath[@]};
            do
                echo $opt;
                break;
            done;
        else
            opt=${exepath[0]};
        fi;
    fi;
    arg=${opt}
}
_roscomplete () 
{ 
    local arg opts;
    COMPREPLY=();
    arg="${COMP_WORDS[COMP_CWORD]}";
    opts="`_ros_list_packages` `_ros_list_stacks`";
    IFS='
';
    COMPREPLY=($(compgen -W "${opts}" -- ${arg}));
    unset IFS
}
_roscomplete_exe () 
{ 
    _roscomplete_search_dir "-type f -perm +111"
}
_roscomplete_file () 
{ 
    _roscomplete_search_dir "-type f ! -regex .*[.][oa]$"
}
_roscomplete_launch () 
{ 
    arg="${COMP_WORDS[COMP_CWORD]}";
    COMPREPLY=();
    if [[ ${arg} =~ \-\-.* ]]; then
        COMPREPLY=(${COMPREPLY[@]} $(compgen -W "--files --args --nodes --find-node --child --local --screen --server_uri --run_id --wait --port --core --pid --dump-params" -- ${arg}));
    else
        _roscomplete_search_dir "( -type f -regex .*\.launch$ -o -type f -regex .*\.test$ )";
        if [[ $COMP_CWORD == 1 ]]; then
            COMPREPLY=($(compgen -o plusdirs -f -X "!*.launch" -- ${arg}) ${COMPREPLY[@]} $(compgen -o plusdirs -f -X "!*.test" -- ${arg}) ${COMPREPLY[@]});
        fi;
    fi
}
_roscomplete_rosbag () 
{ 
    local opts;
    COMPREPLY=();
    arg="${COMP_WORDS[COMP_CWORD]}";
    if [[ $COMP_CWORD == 1 ]]; then
        opts="check compress decompress filter fix help info play record reindex";
        COMPREPLY=($(compgen -W "$opts" -- ${arg}));
    else
        if [[ ${arg} =~ \-\-.* ]]; then
            case ${COMP_WORDS[1]} in 
                check)
                    opts="--genrules --append --noplugins --help"
                ;;
                compress | decompress)
                    opts="--output-dir --force --quiet --help"
                ;;
                filter)
                    opts="--print --help"
                ;;
                fix)
                    opts="--force --noplugins --help"
                ;;
                info)
                    opts="--yaml --key --freq --help"
                ;;
                play)
                    opts="--help --quiet --immediate --pause --queue --clock --hz --delay --rate --start --skip-empty --loop --keep-alive --try-future-version --topics --bags"
                ;;
                record)
                    opts="--help --all --regex --exclude --quiet --output-prefix --output-name --split --size --duration --buffsize --limit --node --bz2"
                ;;
                reindex)
                    opts="--help --force --quiet --output-dir"
                ;;
            esac;
            COMPREPLY=($(compgen -W "$opts" -- ${arg}));
        fi;
    fi
}
_roscomplete_rosclean () 
{ 
    local arg opts;
    COMPREPLY=();
    arg="${COMP_WORDS[COMP_CWORD]}";
    if [[ $COMP_CWORD == 1 ]]; then
        opts="check purge";
        COMPREPLY=($(compgen -W "$opts" -- ${arg}));
    fi
}
_roscomplete_roscreate_pkg () 
{ 
    local arg opts;
    COMPREPLY=();
    arg="${COMP_WORDS[COMP_CWORD]}";
    if [[ $COMP_CWORD != 1 ]]; then
        opts=`rospack list-names`;
        COMPREPLY=($(compgen -W "$opts" -- ${arg}));
    fi
}
_roscomplete_rosmake () 
{ 
    local arg;
    COMPREPLY=();
    arg="${COMP_WORDS[COMP_CWORD]}";
    _roscomplete;
    if [[ ${arg} =~ \-\-.* ]]; then
        COMPREPLY=(${COMPREPLY[@]} $(compgen -W "--test-only --all --mark-installed --unmark-installed --robust --build-everything --specified-only --buildtest --buildtest1 --output --pre-clean --bootstrap --disable-logging --target --pjobs= --threads --profile --skip-blacklist --status-rate" -- ${arg}));
    fi
}
_roscomplete_rosmsg () 
{ 
    local arg opts;
    COMPREPLY=();
    arg="${COMP_WORDS[COMP_CWORD]}";
    if [[ $COMP_CWORD == 1 ]]; then
        opts="show list md5 package packages";
        COMPREPLY=($(compgen -W "$opts" -- ${arg}));
    else
        if [[ $COMP_CWORD == 2 ]]; then
            case ${COMP_WORDS[1]} in 
                show | users | md5)
                    opts=`_msg_opts ${COMP_WORDS[$COMP_CWORD]}`;
                    COMPREPLY=($(compgen -W "$opts" -- ${arg}))
                ;;
                package)
                    opts=`rospack list-names`;
                    COMPREPLY=($(compgen -W "$opts" -- ${arg}))
                ;;
                packages | list)

                ;;
            esac;
        fi;
    fi
}
_roscomplete_rosnode () 
{ 
    local arg opts;
    COMPREPLY=();
    arg="${COMP_WORDS[COMP_CWORD]}";
    if [[ $COMP_CWORD == 1 ]]; then
        opts="ping list info machine kill";
        COMPREPLY=($(compgen -W "$opts" -- ${arg}));
    else
        if [[ $COMP_CWORD == 2 ]]; then
            case ${COMP_WORDS[1]} in 
                info)
                    opts=`rosnode list 2> /dev/null`;
                    COMPREPLY=($(compgen -W "$opts" -- ${arg}))
                ;;
                ping | list | kill)
                    if [[ ${arg} =~ \-\-.* ]]; then
                        opts="--all --help";
                    else
                        opts=`rosnode list 2> /dev/null`;
                    fi;
                    COMPREPLY=($(compgen -W "$opts" -- ${arg}))
                ;;
                machine)

                ;;
            esac;
        else
            case ${COMP_WORDS[1]} in 
                kill)
                    opts=`rosnode list 2> /dev/null`;
                    COMPREPLY=($(compgen -W "$opts" -- ${arg}))
                ;;
            esac;
        fi;
    fi
}
_roscomplete_rospack () 
{ 
    local arg opts;
    COMPREPLY=();
    arg="${COMP_WORDS[COMP_CWORD]}";
    if [[ $COMP_CWORD == 1 ]]; then
        opts="help find list list-names list-duplicates langs depends depends-manifests depends1 depends-indent depends-msgsrv depends-why rosdep rosdep0 vcs vcs0 depends-on depends-on1 export plugins cflags-only-I cflags-only-other libs-only-L libs-only-l libs-only-other profile";
        COMPREPLY=($(compgen -W "$opts" -- ${arg}));
    else
        opts=`rospack list-names`;
        COMPREPLY=($(compgen -W "$opts" -- ${arg}));
    fi
}
_roscomplete_rosparam () 
{ 
    local arg opts;
    COMPREPLY=();
    arg="${COMP_WORDS[COMP_CWORD]}";
    if [[ $COMP_CWORD == 1 ]]; then
        opts="set get load dump delete list";
        COMPREPLY=($(compgen -W "$opts" -- ${arg}));
    else
        if [[ $COMP_CWORD == 2 ]]; then
            case ${COMP_WORDS[1]} in 
                set | get | delete | list)
                    opts=`rosparam list 2> /dev/null`;
                    COMPREPLY=($(compgen -W "$opts" -- ${arg}))
                ;;
                load | dump)
                    COMPREPLY=($(compgen -f -- ${arg}))
                ;;
            esac;
        else
            if [[ $COMP_CWORD == 3 ]]; then
                case ${COMP_WORDS[1]} in 
                    load | dump)
                        opts=`rosparam list 2> /dev/null`;
                        COMPREPLY=($(compgen -W "$opts" -- ${arg}))
                    ;;
                esac;
            fi;
        fi;
    fi
}
_roscomplete_rosservice () 
{ 
    local arg opts;
    COMPREPLY=();
    arg="${COMP_WORDS[COMP_CWORD]}";
    if [[ $COMP_CWORD == 1 ]]; then
        opts="list call type find uri";
        COMPREPLY=($(compgen -W "$opts" -- ${arg}));
    else
        if [[ $COMP_CWORD == 2 ]]; then
            case ${COMP_WORDS[1]} in 
                uri | list | type | call)
                    opts=`rosservice list 2> /dev/null`;
                    COMPREPLY=($(compgen -W "$opts" -- ${arg}))
                ;;
                find)
                    opts=`_srv_opts ${COMP_WORDS[$COMP_CWORD]}`;
                    COMPREPLY=($(compgen -W "$opts" -- ${arg}))
                ;;
            esac;
        else
            if [[ $COMP_CWORD == 3 ]]; then
                case ${COMP_WORDS[1]} in 
                    call)
                        type=`rosservice type ${COMP_WORDS[2]}`;
                        opts=`rosmsg-proto srv 2> /dev/null -s ${type}`;
                        if [ 0 -eq $? ]; then
                            COMPREPLY="$opts";
                        fi
                    ;;
                esac;
            fi;
        fi;
    fi
}
_roscomplete_rossrv () 
{ 
    COMPREPLY=();
    arg="${COMP_WORDS[COMP_CWORD]}";
    if [[ $COMP_CWORD == 1 ]]; then
        opts="show list md5 package packages";
        COMPREPLY=($(compgen -W "$opts" -- ${arg}));
    else
        if [[ $COMP_CWORD == 2 ]]; then
            case ${COMP_WORDS[1]} in 
                show | users | md5)
                    opts=`_srv_opts ${COMP_WORDS[$COMP_CWORD]}`;
                    COMPREPLY=($(compgen -W "$opts" -- ${arg}))
                ;;
                package)
                    opts=`rospack list-names`;
                    COMPREPLY=($(compgen -W "$opts" -- ${arg}))
                ;;
                packages | list)

                ;;
            esac;
        fi;
    fi
}
_roscomplete_rostopic () 
{ 
    local arg opts;
    COMPREPLY=();
    arg="${COMP_WORDS[COMP_CWORD]}";
    if [[ $COMP_CWORD == 1 ]]; then
        opts="bw echo hz list pub type find info";
        COMPREPLY=($(compgen -W "$opts" -- ${arg}));
    else
        if [[ $COMP_CWORD -ge 2 ]]; then
            if [[ ${arg} =~ \-\-.* ]]; then
                case ${COMP_WORDS[1]} in 
                    pub)
                        COMPREPLY=($(compgen -W "--rate --once --file --latch" -- ${arg}))
                    ;;
                    bw)
                        COMPREPLY=($(compgen -W "--window" -- ${arg}))
                    ;;
                    echo)
                        COMPREPLY=($(compgen -W "--bag --filter --nostr --noarr --clear --all offset" -- ${arg}))
                    ;;
                    hz)
                        COMPREPLY=($(compgen -W "--window --filter" -- ${arg}))
                    ;;
                    list)
                        COMPREPLY=($(compgen -W "--bag --verbose --host" -- ${arg}))
                    ;;
                esac;
            else
                case ${COMP_WORDS[1]} in 
                    bw | echo | hz | list | type | info)
                        if [[ ${COMP_WORDS[$(( $COMP_CWORD - 1 ))]} == "-b" ]]; then
                            COMPREPLY=($(compgen -f -- ${arg}));
                        else
                            opts=`rostopic list 2> /dev/null`;
                            COMPREPLY=($(compgen -W "$opts" -- ${arg}));
                        fi
                    ;;
                    find)
                        opts=`_msg_opts ${COMP_WORDS[$COMP_CWORD]}`;
                        COMPREPLY=($(compgen -W "$opts" -- ${arg}))
                    ;;
                    pub)
                        if [[ $COMP_CWORD == 2 ]]; then
                            opts=`rostopic list 2> /dev/null`;
                            COMPREPLY=($(compgen -W "$opts" -- ${arg}));
                        else
                            if [[ $COMP_CWORD == 3 ]]; then
                                opts=`_msg_opts ${COMP_WORDS[$COMP_CWORD]}`;
                                COMPREPLY=($(compgen -W "$opts" -- ${arg}));
                            else
                                if [[ $COMP_CWORD == 4 ]]; then
                                    opts=`rosmsg-proto msg 2> /dev/null -s ${COMP_WORDS[3]}`;
                                    if [ 0 -eq $? ]; then
                                        COMPREPLY="$opts";
                                    fi;
                                fi;
                            fi;
                        fi
                    ;;
                esac;
            fi;
        fi;
    fi
}
_roscomplete_roswtf () 
{ 
    local arg;
    COMPREPLY=();
    arg="${COMP_WORDS[COMP_CWORD]}";
    if [[ ${arg} =~ \-\-.* ]]; then
        COMPREPLY=($(compgen -W "--all --no-plugins --offline" -- ${arg}));
    else
        if [[ $COMP_CWORD == 1 ]]; then
            COMPREPLY=($(compgen -o plusdirs -f -X "!*.launch" -- ${arg}));
        fi;
    fi
}
_roscomplete_search_dir () 
{ 
    local arg opts pkgdir catkin_source_dir catkin_binary_dir;
    COMPREPLY=();
    arg="${COMP_WORDS[COMP_CWORD]}";
    if [[ $COMP_CWORD == 1 ]]; then
        opts=`_ros_list_packages`;
        IFS='
';
        COMPREPLY=($(compgen -W "${opts}" -- ${arg}));
        unset IFS;
    else
        if [[ $COMP_CWORD == 2 ]]; then
            if [[ -n "$CATKIN_SOURCE_DIR" ]]; then
                catkin_source_dir=`ROS_ROOT=$CATKIN_SOURCE_DIR ROS_PACKAGE_PATH= _ros_package_find ${COMP_WORDS[1]}`;
            fi;
            if [[ -n $CATKIN_BINARY_DIR && -f $CATKIN_BINARY_DIR/etc/packages.list ]]; then
                cbd=`grep ${COMP_WORDS[1]} $CATKIN_BINARY_DIR/etc/packages.list | cut -d " " -f 2`;
                if [[ -n $cbd ]]; then
                    catkin_binary_dir=$CATKIN_BINARY_DIR/$cbd;
                fi;
            fi;
            pkgdir=`_ros_package_find ${COMP_WORDS[1]}`;
            if [[ -n "$catkin_source_dir" || -n "$catkin_binary_dir" || -n "$pkgdir" ]]; then
                opts=`_rosfind -L $catkin_source_dir $catkin_binary_dir $pkgdir ${1} ! -regex ".*/[.].*" ! -regex ".*$pkgdir\/build\/.*"  -print0 | tr '\000' '\n' | sed -e "s/.*\/\(.*\)/\1/g"`;
            else
                opts="";
            fi;
            IFS='
';
            COMPREPLY=($(compgen -W "${opts}" -- ${arg}));
            unset IFS;
        else
            homedir=`echo $HOME | sed -e "s/\//\t\//g" -e "s/\t/\\\\\/g"`;
            arg=`echo ${arg} | sed -e "s/~/${homedir}/g"`;
            if [[ $arg =~ ^/*.+/.* ]]; then
                path=${arg%/*};
            else
                path=.;
            fi;
            if [[ -e ${path} ]]; then
                opts=`find -L $path -maxdepth 1 -type d ! -regex ".*/[.].*" ! -regex "^[.]/" -print0 | tr '\000' '\n' | sed -e "s/$/\//g" -e "s/^[.]\///g" -e "s/'/\\\\\'/g" -e "s/ /\\\\\ /g"`'
'`find -L $path -maxdepth 1 -type f ! -regex ".*/[.][^.]*" ! -regex "^[.]/" -print0 | tr '\000' '\n' | sed -e "s/^[.]\///g"  -e "s/'/\\\\\'/g" -e "s/ /\\\\\ /g"`;
            else
                opts="";
            fi;
            IFS='
';
            COMPREPLY=($(compgen -W "$opts" -- ${arg}));
            unset IFS;
            if [[ ${#COMPREPLY[*]} = 1 ]]; then
                newpath=${COMPREPLY[0]%/*};
                if [[ -d ${newpath} ]]; then
                    opts=`find -L $newpath -maxdepth 1 -type d ! -regex ".*/[.].*" ! -regex "^[.]/" -print0 | tr '\000' '\n' | sed -e "s/$/\//g" -e "s/^[.]\///g" -e "s/'/\\\\\'/g" -e "s/ /\\\\\ /g"`'
'`find -L $newpath -maxdepth 1 -type f ! -regex ".*/[.][^.]*" ! -regex "^[.]/" -print0 | tr '\000' '\n' | sed -e "s/^[.]\///g"  -e "s/'/\\\\\'/g" -e "s/ /\\\\\ /g"`;
                    IFS='
';
                    COMPREPLY=($(compgen -W "$opts" -- ${arg}));
                    unset IFS;
                fi;
            fi;
        fi;
    fi
}
_roscomplete_sub_dir () 
{ 
    local arg opts rosvals;
    COMPREPLY=();
    arg="${COMP_WORDS[COMP_CWORD]}";
    _ros_decode_path ${arg};
    if [[ -z ${rosvals[2]} ]]; then
        opts=`_ros_list_locations`;
        IFS='
';
        COMPREPLY=($(compgen -W "${opts}" -S / -- ${rosvals[0]}));
        unset IFS;
    else
        if [ -e ${rosvals[1]}${rosvals[2]} ]; then
            opts=`find -L ${rosvals[1]}${rosvals[2]} -maxdepth 1 -mindepth 1 -type d ! -regex ".*/[.].*" -print0 | tr '\000' '\n' | sed -e "s/.*\/\(.*\)/\1\//g"`;
        else
            opts='';
        fi;
        IFS='
';
        COMPREPLY=($(compgen -P ${rosvals[0]}${rosvals[2]} -W "${opts}" -- ${rosvals[3]}));
        unset IFS;
    fi
}
_roscomplete_test () 
{ 
    arg="${COMP_WORDS[COMP_CWORD]}";
    if [[ ${arg} =~ \-\-.* ]]; then
        COMPREPLY=(${COMPREPLY[@]} $(compgen -W "--bare --bare-limit --bare-name --pkgdir --package" -- ${arg}));
    else
        _roscomplete_search_dir "( -type f -regex .*\.launch$ -o -type f -regex .*\.test$ )";
        if [[ $COMP_CWORD == 1 ]]; then
            COMPREPLY=($(compgen -o plusdirs -f -X "!*.launch" -- ${arg}) ${COMPREPLY[@]} $(compgen -o plusdirs -f -X "!*.test" -- ${arg}) ${COMPREPLY[@]});
        fi;
    fi
}
_rosfind () 
{ 
    if [[ `uname` == Darwin || `uname` == FreeBSD ]]; then
        find -E "$@";
    else
        find "$@";
    fi
}
_rossed () 
{ 
    if [[ `uname` == Darwin || `uname` == FreeBSD ]]; then
        sed -E "$@";
    else
        sed -r "$@";
    fi
}
_route () 
{ 
    local cur prev;
    COMPREPLY=();
    cur=`_get_cword`;
    prev=${COMP_WORDS[COMP_CWORD-1]};
    if [ "$prev" = dev ]; then
        COMPREPLY=($( ifconfig -a | sed -ne 's|^\('$cur'[^ ]*\).*$|\1|p' ));
        return 0;
    fi;
    COMPREPLY=($( compgen -W 'add del -host -net netmask metric mss \
        window irtt reject mod dyn reinstate dev \
        default gw' -- "$cur" ));
    COMPREPLY=($( echo " ${COMP_WORDS[@]}" |         (while read -d ' ' i; do
            [ "$i" == "" ] && continue
            # flatten array with spaces on either side,
            # otherwise we cannot grep on word
            # boundaries of first and last word
            COMPREPLY=" ${COMPREPLY[@]} "
            # remove word from list of completions
            COMPREPLY=( ${COMPREPLY/ $i / } )
        done
           echo "${COMPREPLY[@]}")
        ));
    return 0
}
_rpcdebug () 
{ 
    local cur prev;
    COMPREPLY=();
    cur=`_get_cword`;
    prev=${COMP_WORDS[COMP_CWORD-1]};
    case $prev in 
        -s)
            _rpcdebug_flags;
            return 0
        ;;
        -c)
            _rpcdebug_flags;
            return 0
        ;;
        -m)
            COMPREPLY=($( compgen -W 'rpc nfs nfsd nlm' -- "$cur" ));
            return 0
        ;;
    esac;
    if [[ "$cur" == -* ]]; then
        COMPREPLY=($( compgen -W '-v -h -m -s -c' -- "$cur" ));
    fi
}
_rpcdebug_flags () 
{ 
    local i module;
    for ((i=0; i < ${#COMP_WORDS[@]}; i++ ))
    do
        if [[ ${COMP_WORDS[i]} == -m ]]; then
            module=${COMP_WORDS[i+1]};
        fi;
    done;
    if [ -n "$module" ]; then
        COMPREPLY=($( compgen -W "$(rpcdebug -vh 2>&1             | grep '^'$module' '            | awk '{$1 = ""; print $0}')" -- "$cur" ));
    fi
}
_rpm () 
{ 
    local cur prev opts nodig nosig;
    COMPREPLY=();
    cur=`_get_cword`;
    prev=${COMP_WORDS[COMP_CWORD-1]};
    nodig="";
    nosig="";
    _rpm_nodigsig;
    if [ $COMP_CWORD -eq 1 ]; then
        case "$cur" in 
            -b*)
                COMPREPLY=($( compgen -W '-ba -bb -bc -bi -bl -bp -bs'                     -- "$cur" ))
            ;;
            -t*)
                COMPREPLY=($( compgen -W '-ta -tb -tc -ti -tl -tp -ts'                     -- "$cur" ))
            ;;
            --*)
                COMPREPLY=($( compgen -W '--help --version --initdb \
                    --checksig --recompile --rebuild --resign --addsign \
                    --rebuilddb --showrc --setperms --setugids --tarbuild \
                    --eval --install --upgrade --query --freshen --erase \
                    --verify --querytags --rmsource --rmspec --clean \
                    --import' -- "$cur" ))
            ;;
            *)
                COMPREPLY=($( compgen -W '-b -e -E -F -i -q -t -U -V'                     -- "$cur" ))
            ;;
        esac;
        return 0;
    fi;
    case "$prev" in 
        --@(@(db|exclude)path|prefix|relocate|root))
            _filedir -d;
            return 0
        ;;
        --eval | -E)
            COMPREPLY=($( rpm --showrc | sed -ne                 's/^-\?[0-9]\+[:=][[:space:]]\+\('${cur#%}'[^[:space:](]*\).*/\1/p' ));
            COMPREPLY=("${COMPREPLY[@]/#/%}");
            return 0
        ;;
        --pipe)
            COMPREPLY=($( compgen -c -- "$cur" ));
            return 0
        ;;
        --rcfile)
            _filedir;
            return 0
        ;;
        --specfile)
            _filedir spec;
            return 0
        ;;
        --whatprovides)
            if [[ "$cur" == */* ]]; then
                _filedir;
            else
                local IFS='
';
                COMPREPLY=($( compgen -W "$( rpm -qa $nodig $nosig                 --queryformat='%{providename}\n' )" -- "$cur" ));
            fi;
            return 0
        ;;
        --whatrequires)
            if [[ "$cur" == */* ]]; then
                _filedir;
            else
                local IFS='
';
                COMPREPLY=($( compgen -W "$( rpm -qa $nodig $nosig                         --queryformat='%{requirename}\n' )"                         -- "$cur" ));
            fi;
            return 0
        ;;
        --target)
            COMPREPLY=($( compgen -W "$( command rpm --showrc | sed -ne                 's/^\s*compatible\s\+build\s\+archs\s*:\s*\(.*\)/\1/ p' )"                 -- "$cur" ));
            return 0
        ;;
        --define | -D)
            return 0
        ;;
    esac;
    opts="--define --eval --macros --nodigest --nosignature --rcfile         --quiet --pipe --verbose";
    case "${COMP_WORDS[1]}" in 
        -@([iFU]*|-install|-freshen|-upgrade))
            if [[ "$cur" == -* ]]; then
                COMPREPLY=($( compgen -W "$opts --percent --force                 --test --replacepkgs --replacefiles --root                 --excludedocs --includedocs --noscripts --ignorearch                 --dbpath --prefix --ignoreos --nodeps --allfiles                 --ftpproxy --ftpport --justdb --httpproxy --httpport                 --noorder --relocate --badreloc --notriggers                 --excludepath --ignoresize --oldpackage                 --queryformat --repackage --nosuggests" -- "$cur" ));
            else
                _filedir 'rpm';
            fi
        ;;
        -@(e|-erase))
            if [[ "$cur" == -* ]]; then
                COMPREPLY=($( compgen -W "$opts --allmatches                 --noscripts --notriggers --nodeps --test --repackage"                 -- "$cur" ));
            else
                _rpm_installed_packages "$nodig" "$nosig";
            fi
        ;;
        -@(q*|-query))
            opts="$opts --changelog --configfiles --conflicts --docfiles
                --dump --enhances --filesbypkg --filecaps --fileclass
                --filecolor --fileprovide --filerequire --filesbypkg
                --info --list --obsoletes --pipe --provides
                --queryformat --rcfile --requires --scripts --suggests
                --triggeredby --triggers --whatprovides --whatrequires --xml";
            if [ "${COMP_LINE#* -*([^ -])f}" != "$COMP_LINE" ]; then
                if [[ "$cur" == -* ]]; then
                    COMPREPLY=($( compgen -W "$opts --dbpath --fscontext                         --last --root --state" -- "$cur" ));
                else
                    _filedir;
                fi;
            else
                if [ "${COMP_LINE#* -*([^ -])g}" != "$COMP_LINE" ]; then
                    _rpm_groups;
                else
                    if [ "${COMP_LINE#* -*([^ -])p}" != "$COMP_LINE" ]; then
                        if [[ "$cur" == -* ]]; then
                            COMPREPLY=($( compgen -W "$opts --ftpport --ftpproxy                         --httpport --httpproxy" -- "$cur" ));
                        else
                            _filedir 'rpm';
                        fi;
                    else
                        if [[ "$cur" == -* ]]; then
                            COMPREPLY=($( compgen -W "$opts --dbpath --fscontext                         --last --root --state" -- "$cur" ));
                        else
                            if [ "${COMP_LINE#* -*([^ -])a}" == "$COMP_LINE" ]; then
                                _rpm_installed_packages "$nodig" "$nosig";
                            fi;
                        fi;
                    fi;
                fi;
            fi
        ;;
        -@(K*|-checksig))
            if [[ "$cur" == -* ]]; then
                COMPREPLY=($( compgen -W "$opts --nopgp --nogpg --nomd5"                     -- "$cur" ));
            else
                _filedir 'rpm';
            fi
        ;;
        -@([Vy]*|-verify))
            if [[ "$cur" == -* ]]; then
                COMPREPLY=($( compgen -W "$opts --root --dbpath --nodeps                     --nogroup --nolinkto --nomode --nomtime --nordev --nouser                     --nofiles --noscripts --nomd5 --querytags --specfile                     --whatrequires --whatprovides" -- "$cur" ));
            else
                if [ "${COMP_LINE#* -*([^ -])f}" != "$COMP_LINE" ]; then
                    _filedir;
                else
                    if [ "${COMP_LINE#* -*([^ -])g}" != "$COMP_LINE" ]; then
                        _rpm_groups;
                    else
                        if [ "${COMP_LINE#* -*([^ -])p}" != "$COMP_LINE" ]; then
                            _filedir 'rpm';
                        else
                            _rpm_installed_packages "$nodig" "$nosig";
                        fi;
                    fi;
                fi;
            fi
        ;;
        -[bt]*)
            if [[ "$cur" == -* ]]; then
                COMPREPLY=($( compgen -W "$opts --short-circuit --timecheck                     --clean --rmsource --rmspec --test --sign --buildroot                     --target --nobuild --nodeps --nodirtokens" -- "$cur" ));
            else
                if [[ ${COMP_WORDS[1]} == -b* ]]; then
                    _filedir 'spec';
                else
                    _filedir '@(t?(ar.)@([gx]z|bz?(2))|tar.@(lzma|Z))';
                fi;
            fi
        ;;
        --re@(build|compile))
            if [[ "$cur" == -* ]]; then
                COMPREPLY=($( compgen -W "$opts --nodeps --rmsource                   --rmspec --sign --nodirtokens --target" -- "$cur" ));
            else
                _filedir '?(no)src.rpm';
            fi
        ;;
        --tarbuild)
            _filedir '@(t?(ar.)@([gx]z|bz?(2))|tar.@(lzma|Z))'
        ;;
        --@(re|add)sign)
            _filedir 'rpm'
        ;;
        --set@(perms|gids))
            _rpm_installed_packages "$nodig" "$nosig"
        ;;
        --@(clean|rms@(ource|pec)))
            if [[ "$cur" == -* ]]; then
                COMPREPLY=($( compgen -W '--clean --rmsource --rmspec'                     -- "$cur" ));
            else
                _filedir 'spec';
            fi
        ;;
        --@(import|dbpath|root))
            if [[ "$cur" == -* ]]; then
                COMPREPLY=($( compgen -W '--import --dbpath --root'                     -- "$cur" ));
            else
                _filedir;
            fi
        ;;
    esac;
    return 0
}
_rpm_groups () 
{ 
    local IFS='
';
    COMPREPLY=($( compgen -W "$( rpm -qa $nodig $nosig --queryformat         '%{group}\n' )" -- "$cur" ))
}
_rpm_installed_packages () 
{ 
    local nodig="$1" nosig="$2";
    if [ -r /var/log/rpmpkgs -a /var/log/rpmpkgs -nt /var/lib/rpm/Packages ]; then
        COMPREPLY=($( sed -ne             's|^\('$cur'[^[:space:]]*\)-[^[:space:]-]\+-[^[:space:]-]\+\.rpm$|\1|p'             /var/log/rpmpkgs ));
    else
        _rpm_nodigsig;
        COMPREPLY=($( rpm -qa $nodig $nosig --qf='%{NAME} ' "$cur*" ));
    fi
}
_rpm_nodigsig () 
{ 
    if [ -z "$nodig" -a -z "$nosig" ]; then
        local rpmver;
        rpmver=$(rpm --version);
        rpmver=${rpmver##* };
        if [[ "$rpmver" > "4.0.4" ]]; then
            nodig="--nodigest";
        fi;
        if [[ "$rpmver" > "4.0.99" ]]; then
            nosig="--nosignature";
        fi;
    fi
}
_rsync () 
{ 
    local cur prev shell i userhost path;
    COMPREPLY=();
    cur=`_get_cword`;
    prev=${COMP_WORDS[COMP_CWORD-1]};
    _expand || return 0;
    case "$prev" in 
        --@(config|password-file|include-from|exclude-from))
            _filedir;
            return 0
        ;;
        -@(T|-temp-dir|-compare-dest))
            _filedir -d;
            return 0
        ;;
        -@(e|-rsh))
            COMPREPLY=($( compgen -W 'rsh ssh' -- "$cur" ));
            return 0
        ;;
    esac;
    case "$cur" in 
        -*)
            COMPREPLY=($( compgen -W '-v -q  -c -a -r -R -b -u -l -L -H \
            -p -o -g -D -t -S -n -W -x -B -e -C -I -T -P \
            -z -h -4 -6 --verbose --quiet --checksum \
            --archive --recursive --relative --backup \
            --backup-dir --suffix= --update --links \
            --copy-links --copy-unsafe-links --safe-links \
            --hard-links --perms --owner --group --devices\
            --times --sparse --dry-run --whole-file \
            --no-whole-file --one-file-system \
            --block-size= --rsh= --rsync-path= \
            --cvs-exclude --existing --ignore-existing \
            --delete --delete-excluded --delete-after \
            --ignore-errors --max-delete= --partial \
            --force --numeric-ids --timeout= \
            --ignore-times --size-only --modify-window= \
            --temp-dir= --compare-dest= --compress \
            --exclude= --exclude-from= --include= \
            --include-from= --version --daemon --no-detach\
            --address= --config= --port= --blocking-io \
            --no-blocking-io --stats --progress \
            --log-format= --password-file= --bwlimit= \
            --write-batch= --read-batch= --help' -- "$cur" ))
        ;;
        *:*)
            shell=ssh;
            for ((i=1; i < COMP_CWORD; i++ ))
            do
                if [[ "${COMP_WORDS[i]}" == -@(e|-rsh) ]]; then
                    shell=${COMP_WORDS[i+1]};
                    break;
                fi;
            done;
            if [[ "$shell" == ssh ]]; then
                cur=${cur/\\:/:};
                userhost=${cur%%?(\\):*};
                path=${cur#*:};
                path=${path//\\\\\\\\ / };
                if [ -z "$path" ]; then
                    path=$(ssh -o 'Batchmode yes' $userhost pwd 2>/dev/null);
                fi;
                COMPREPLY=($( ssh -o 'Batchmode yes' $userhost                 command ls -aF1d "$path*" 2>/dev/null |                 sed -e 's/ /\\\\\\\ /g' -e 's/[*@|=]$//g'                 -e 's/[^\/]$/& /g' ));
            fi
        ;;
        *)
            _known_hosts_real -c -a "$cur";
            _filedir
        ;;
    esac;
    return 0
}
_samba_debuglevel () 
{ 
    COMPREPLY=($( compgen -W '0 1 2 3 4 5 6 7 8 9 10' -- "$cur" ))
}
_samba_domains () 
{ 
    if [ -n "${COMP_SAMBA_SCAN:-}" ]; then
        COMPREPLY=($( compgen -W '$( smbtree -N -D )' -- "$cur" ));
    fi
}
_samba_hosts () 
{ 
    if [ -n "${COMP_SAMBA_SCAN:-}" ]; then
        COMPREPLY=($( compgen -W "$( smbtree -N -S |             sed -ne 's/^[[:space:]]*\\\\*\([^[:space:]]*\).*/\1/p'             )" -- $cur ));
    fi
}
_samba_resolve_order () 
{ 
    COMPREPLY=($( compgen -W 'lmhosts host wins bcast' -- "$cur" ))
}
_scp () 
{ 
    local configfile cur userhost path prefix;
    COMPREPLY=();
    cur=`_get_cword ":"`;
    _expand || return 0;
    if [[ "$cur" == *:* ]]; then
        local IFS='	
';
        cur=${cur/\\:/:};
        userhost=${cur%%?(\\):*};
        path=${cur#*:};
        path=${path//\\\\\\\\ / };
        if [ -z "$path" ]; then
            path=$(ssh -o 'Batchmode yes' $userhost pwd 2>/dev/null);
        fi;
        COMPREPLY=($( ssh -o 'Batchmode yes' $userhost             command ls -aF1d "$path*" 2>/dev/null |             sed -e "s/[][(){}<>\",:;^&\!$=?\`|\\ ']/\\\\\\\\\\\\&/g"             -e 's/[*@|=]$//g' -e 's/[^\/]$/& /g' ));
        return 0;
    fi;
    if [[ "$cur" = -F* ]]; then
        cur=${cur#-F};
        prefix=-F;
    else
        set -- "${COMP_WORDS[@]}";
        while [ $# -gt 0 ]; do
            if [ "${1:0:2}" = -F ]; then
                if [ ${#1} -gt 2 ]; then
                    configfile="$(dequote "${1:2}")";
                else
                    shift;
                    [ "$1" ] && configfile="$(dequote "$1")";
                fi;
                break;
            fi;
            shift;
        done;
        [[ "$cur" == */* ]] || _known_hosts_real -c -a -F "$configfile" "$cur";
    fi;
    local IFS='	
';
    COMPREPLY=("${COMPREPLY[@]}" $( command ls -aF1d $cur* 2>/dev/null | sed         -e "s/[][(){}<>\",:;^&\!$=?\`|\\ ']/\\\\&/g"         -e 's/[*@|=]$//g' -e 's/[^\/]$/& /g' -e "s/^/$prefix/"));
    return 0
}
_screen () 
{ 
    local cur prev preprev;
    COMPREPLY=();
    cur=`_get_cword`;
    prev=${COMP_WORDS[COMP_CWORD-1]};
    [ "$COMP_CWORD" -ge 2 ] && preprev=${COMP_WORDS[COMP_CWORD-2]};
    case "$preprev" in 
        -[dD])
            _screen_sessions;
            return 0
        ;;
    esac;
    case "$prev" in 
        -[rR])
            _screen_sessions 'Detached';
            return 0
        ;;
        -[dDx])
            _screen_sessions 'Attached';
            return 0
        ;;
        -s)
            COMPREPLY=($( grep ^${cur:-[^#]} /etc/shells ))
        ;;
        -c)
            _filedir;
            return 0
        ;;
    esac;
    if [[ "$cur" == -* ]]; then
        COMPREPLY=($( compgen -W '-a -A -c -d -D -e -f -fn -fa -h -i \
            -l -ln -ls -list -L -m -O -p -q -r -R -s -S -t -U -v \
            -wipe -x -X' -- "$cur" ));
    fi
}
_screen_sessions () 
{ 
    local pattern;
    if [ -n "$1" ]; then
        pattern=".*$1.*";
    else
        pattern=".*";
    fi;
    COMPREPLY=($( command screen -ls | sed -ne         's|^[''	'']\+\('"$cur"'[0-9]\+\.[^''	'']\+\)'"$pattern"'$|\1|p' ))
}
_sdptool () 
{ 
    local cur prev split=false;
    COMPREPLY=();
    cur=`_get_cword`;
    prev=${COMP_WORDS[COMP_CWORD-1]};
    _split_longopt && split=true;
    case $prev in 
        --bdaddr)
            _bluetooth_adresses;
            return 0
        ;;
    esac;
    $split && return 0;
    _get_command;
    if [ -z $command ]; then
        if [[ "$cur" == -* ]]; then
            COMPREPLY=($( compgen -W '--help' -- "$cur" ));
        else
            COMPREPLY=($( compgen -W 'search browse records add \
                del get setattr setseq' -- "$cur" ));
        fi;
    else
        case $command in 
            search)
                if [[ "$cur" == -* ]]; then
                    COMPREPLY=($( compgen -W '--bdaddr \
                        --tree --raw --xml' -- "$cur" ));
                else
                    _bluetooth_services;
                fi
            ;;
            @(browse|records))
                if [[ "$cur" == -* ]]; then
                    COMPREPLY=($( compgen -W '--tree --raw --xml' -- "$cur" ));
                else
                    _bluetooth_adresses;
                fi
            ;;
            add)
                if [[ "$cur" == -* ]]; then
                    COMPREPLY=($( compgen -W '--handle --channel' -- "$cur" ));
                else
                    _bluetooth_services;
                fi
            ;;
            get)
                if [[ "$cur" == -* ]]; then
                    COMPREPLY=($( compgen -W '--bdaddr \
                        --tree --raw --xml' -- "$cur" ));
                fi
            ;;
        esac;
    fi
}
_service () 
{ 
    local cur prev sysvdir;
    COMPREPLY=();
    prev=${COMP_WORDS[COMP_CWORD-1]};
    cur=`_get_cword`;
    [[ ${COMP_WORDS[0]} != @(*init.d/!(functions|~)|service) ]] && return 0;
    [ $COMP_CWORD -gt 2 ] && return 0;
    [ -d /etc/rc.d/init.d ] && sysvdir=/etc/rc.d/init.d || sysvdir=/etc/init.d;
    if [[ $COMP_CWORD -eq 1 ]] && [[ $prev == "service" ]]; then
        _services;
    else
        COMPREPLY=($( compgen -W '`sed -ne "y/|/ /; \
            s/^.*\(U\|msg_u\)sage.*{\(.*\)}.*$/\1/p" \
            $sysvdir/${prev##*/} 2>/dev/null`' -- "$cur" ));
    fi;
    return 0
}
_services () 
{ 
    local sysvdir famdir;
    [ -d /etc/rc.d/init.d ] && sysvdir=/etc/rc.d/init.d || sysvdir=/etc/init.d;
    famdir=/etc/xinetd.d;
    COMPREPLY=($( builtin echo $sysvdir/!(*.rpm@(orig|new|save)|*~|functions)));
    if [ -d $famdir ]; then
        COMPREPLY=("${COMPREPLY[@]}" $( builtin echo $famdir/!(*.rpm@(orig|new|save)|*~)));
    fi;
    COMPREPLY=($( compgen -W '${COMPREPLY[@]#@($sysvdir|$famdir)/}' -- "$cur" ))
}
_sftp () 
{ 
    local cur prev configfile;
    COMPREPLY=();
    cur=`_get_cword`;
    prev=${COMP_WORDS[COMP_CWORD-1]};
    case "$prev" in 
        -@(b|F|P))
            _filedir;
            return 0
        ;;
        -o)
            _ssh_options;
            return 0
        ;;
    esac;
    if [[ "$cur" == -F* ]]; then
        cur=${cur#-F};
        _filedir;
        COMPREPLY=("${COMPREPLY[@]/#/-F}");
        cur=-F$cur;
    else
        if [[ "$cur" == -* ]]; then
            COMPREPLY=($( compgen -W '-1 -C -v -B -b -F -o -P -R -S -s' 			-- "$cur" ));
        else
            set -- "${COMP_WORDS[@]}";
            while [ $# -gt 0 ]; do
                if [ "${1:0:2}" = -F ]; then
                    if [ ${#1} -gt 2 ]; then
                        configfile="$(dequote "${1:2}")";
                    else
                        shift;
                        [ "$1" ] && configfile="$(dequote "$1")";
                    fi;
                    break;
                fi;
                shift;
            done;
            _known_hosts_real -a -F "$configfile" "$cur";
        fi;
    fi;
    return 0
}
_shells () 
{ 
    COMPREPLY=("${COMPREPLY[@]}" $( compgen -W '$( grep "^[[:space:]]*/" \
    /etc/shells 2>/dev/null )' -- "$cur" ))
}
_signals () 
{ 
    local i;
    COMPREPLY=($( compgen -A signal SIG${cur#-} ));
    for ((i=0; i < ${#COMPREPLY[@]}; i++ ))
    do
        COMPREPLY[i]=-${COMPREPLY[i]#SIG};
    done
}
_smartctl () 
{ 
    local cur prev split=false;
    COMPREPLY=();
    cur=`_get_cword`;
    prev=${COMP_WORDS[COMP_CWORD-1]};
    _split_longopt && split=true;
    case "$prev" in 
        -q | --quietmode)
            _smartctl_quietmode
        ;;
        -d | --device)
            _smartctl_device;
            return 0
        ;;
        -t | --tolerance)
            _smartctl_tolerance;
            return 0
        ;;
        -b | --badsum)
            _smartctl_badsum;
            return 0
        ;;
        -r | --report)
            _smartctl_report;
            return 0
        ;;
        -n | --nocheck)
            _smartctl_powermode;
            return 0
        ;;
        -s | --smart | -o | --offlineauto | -S | --saveauto)
            _smartctl_feature;
            return 0
        ;;
        -l | --log)
            _smartctl_log;
            return 0
        ;;
        -v | --vendorattribute)
            _smartctl_vendorattribute;
            return 0
        ;;
        -F | --firmwarebug)
            _smartctl_firmwarebug;
            return 0
        ;;
        -P | --presets)
            _smartctl_presets;
            return 0
        ;;
        -t | --test)
            _smartctl_test;
            return 0
        ;;
    esac;
    $split && return 0;
    if [[ "$cur" == -* ]]; then
        COMPREPLY=($( compgen -W '-h --help --usage -V --version \
			--copyright --license-i --info -a --all -q \
			--quietmode -d --device -T --tolerance -b --badsum \
			-r --report -n --nocheck -s --smart -o --offlineauto \
			-S --saveauto -H --health -c --capabilities -A \
			--attributes -l --log -v --vendorattribute -F \
			--firmwarebug -P --presets -t --test -C \
			--captive -X --abort' -- "$cur" ));
    else
        cur=${cur:=/dev/};
        _filedir;
    fi
}
_smartctl_badsum () 
{ 
    COMPREPLY=($( compgen -W 'warn exit ignore' -- "$cur" ))
}
_smartctl_device () 
{ 
    local i opts='ata scsi sat marvell hpt cciss';
    for ((i=0; i <= 31; i++ ))
    do
        opts="$opts 3ware,$i";
    done;
    COMPREPLY=($( compgen -W "$opts" -- "$cur" ))
}
_smartctl_feature () 
{ 
    COMPREPLY=($( compgen -W 'on off' -- "$cur" ))
}
_smartctl_firmwarebug () 
{ 
    COMPREPLY=($( compgen -W 'none samsung samsung2 samsung3 swapid'         -- "$cur" ))
}
_smartctl_log () 
{ 
    COMPREPLY=($( compgen -W 'error selftest selective directory' -- "$cur" ))
}
_smartctl_powermode () 
{ 
    COMPREPLY=($( compgen -W 'never sleep standby idle' -- "$cur" ))
}
_smartctl_presets () 
{ 
    COMPREPLY=($( compgen -W 'use ignore show showall' -- "$cur" ))
}
_smartctl_quietmode () 
{ 
    COMPREPLY=($( compgen -W 'errorsonly silent noserial' -- "$cur" ))
}
_smartctl_report () 
{ 
    COMPREPLY=($( compgen -W 'ioctl ataioctl scsiioctl' -- "$cur" ))
}
_smartctl_test () 
{ 
    COMPREPLY=($( compgen -W 'offline short long conveyance select \
		afterselect,on afterselect,off pending scttempint' -- "$cur" ))
}
_smartctl_tolerance () 
{ 
    COMPREPLY=($( compgen -W 'normal conservative permissive \
		verypermissive' -- "$cur" ))
}
_smartctl_vendorattribute () 
{ 
    COMPREPLY=($( compgen -W 'help 9,minutes 9,seconds 9,halfminutes \
		9,temp 192,emergencyretractcyclect 193,loadunload \
		194,10xCelsius 194,unknown 198,offlinescanuncsectorct \
		200,writeerrorcount 201,detectedtacount 220,temp' -- "$cur" ))
}
_smbcacls () 
{ 
    local cur prev split=false;
    COMPREPLY=();
    cur=`_get_cword`;
    prev=${COMP_WORDS[COMP_CWORD-1]};
    _split_longopt && split=true;
    case $prev in 
        -s)
            _filedir;
            return 0
        ;;
        -l | --log-basename)
            _filedir -d;
            return 0
        ;;
        -d | --debuglevel)
            _samba_debuglevel;
            return 0
        ;;
    esac;
    $split && return 0;
    if [[ "$cur" == -* ]]; then
        COMPREPLY=($( compgen -W '-a -M -D -S -U -C -G --numeric -t \
            -h --help -V -s -d --debuglevel -l --log-basename' -- "$cur" ));
    fi
}
_smbclient () 
{ 
    local cur prev split=false;
    COMPREPLY=();
    cur=`_get_cword`;
    prev=${COMP_WORDS[COMP_CWORD-1]};
    _split_longopt && split=true;
    case $prev in 
        -R)
            _samba_resolve_order;
            return 0
        ;;
        -t)
            COMPREPLY=($( compgen -W 'SJIS EUC JIS7 JIS8 JUNET HEX CAP'                 -- "$cur" ));
            return 0
        ;;
        -s | -A | --authentication-file)
            _filedir;
            return 0
        ;;
        -l | --log-basename | -D)
            _filedir -d;
            return 0
        ;;
        -O)
            COMPREPLY=($( compgen -W 'SO_KEEPALIVE SO_REUSEADDR \
                SO_BROADCAST TCP_NODELAY IPTOS_LOWDELAY \
                IPTOS_THROUGHPUT SO_SNDBUF SO_RCVBUF \
                SO_SNDLOWAT SO_RCVLOWAT' -- "$cur" ));
            return 0
        ;;
        -T)
            COMPREPLY=($( compgen -W 'c x I X F b g q r N a' -- "$cur" ));
            return 0
        ;;
        -W | --workgroup)
            _samba_domains;
            return 0
        ;;
        -d | --debuglevel)
            _samba_debuglevel;
            return 0
        ;;
        -p | --port | -M | -I | -b | -U | --user | -n | -i | -T | -c)
            return 0
        ;;
        -\? | --help | -V | --version)
            return 0
        ;;
    esac;
    $split && return 0;
    if [[ "$cur" == -* ]]; then
        COMPREPLY=($( compgen -W '-b -d -L -U -I -M -m -A -N -i -O \
            -p -R -s -k -P -c -D -W -l -E --debuglevel \
            --log-basename --workgroup' -- "$cur" ));
    fi
}
_smbcquotas () 
{ 
    local cur prev split=false;
    COMPREPLY=();
    cur=`_get_cword`;
    prev=${COMP_WORDS[COMP_CWORD-1]};
    _split_longopt && split=true;
    case $prev in 
        -s | -A | --authentication-file)
            _filedir;
            return 0
        ;;
        -l | --log-basename)
            _filedir -d;
            return 0
        ;;
        -d | --debuglevel)
            _samba_debuglevel;
            return 0
        ;;
    esac;
    $split && return 0;
    if [[ "$cur" == -* ]]; then
        COMPREPLY=($( compgen -W '-u -L -F -S -n -t -v -h --help -V \
            -s -d --debuglevel -l --log-basename -N -k -A \
            --authentication-file -U --user' -- "$cur" ));
    fi
}
_smbget () 
{ 
    local cur prev split=false;
    COMPREPLY=();
    cur=`_get_cword`;
    prev=${COMP_WORDS[COMP_CWORD-1]};
    _split_longopt && split=true;
    case $prev in 
        -@(o|f|-outputfile|-rcfile))
            _filedir;
            return 0
        ;;
        -d | --debuglevel)
            _samba_debuglevel;
            return 0
        ;;
    esac;
    $split && return 0;
    if [[ "$cur" == -* ]]; then
        COMPREPLY=($( compgen -W '-a --guest -r --resume -R --recursive -u \
            --username -p --password -w --workgroup -n --nonprompt -d \
            --debuglevel -D --dots -P --keep-permissions -o --outputfile -f \
            --rcfile -q --quiet -v --verbose -b --blocksize -? --help --usage'             -- "$cur" ));
    fi
}
_smbpasswd () 
{ 
    local cur prev;
    COMPREPLY=();
    cur=`_get_cword`;
    prev=${COMP_WORDS[COMP_CWORD-1]};
    case $prev in 
        -r)
            _samba_hosts;
            return 0
        ;;
        -R)
            _samba_resolve_order;
            return 0
        ;;
        -c)
            _filedir;
            return 0
        ;;
        -D)
            _samba_debuglevel;
            return 0
        ;;
    esac;
    if [[ "$cur" == -* ]]; then
        COMPREPLY=($( compgen -W '-a -c -x -d -e -D -n -r -R -m -U -h \
            -s -w -W -i -L' -- "$cur" ));
    fi
}
_smbtar () 
{ 
    local cur prev;
    COMPREPLY=();
    cur=`_get_cword`;
    prev=${COMP_WORDS[COMP_CWORD-1]};
    case $prev in 
        -@(r|t))
            _filedir tar;
            return 0
        ;;
        -s)
            _samba_hosts;
            return 0
        ;;
        -l)
            _samba_debuglevel;
            return 0
        ;;
    esac;
    if [[ "$cur" == -* ]]; then
        COMPREPLY=($( compgen -W '-r -i -a -v -s -p -x -X -N -b -d -l -u -t'             -- "$cur" ));
    fi
}
_smbtree () 
{ 
    local cur prev split=false;
    COMPREPLY=();
    cur=`_get_cword`;
    prev=${COMP_WORDS[COMP_CWORD-1]};
    _split_longopt && split=true;
    case $prev in 
        -s | -A | --authentication-file)
            _filedir;
            return 0
        ;;
        -l | --log-basename)
            _filedir -d;
            return 0
        ;;
        -d | --debuglevel)
            _samba_debuglevel;
            return 0
        ;;
    esac;
    $split && return 0;
    if [[ "$cur" == -* ]]; then
        COMPREPLY=($( compgen -W '-b -D -S -V -s -d --debuglevel -l \
            --log-basename -N -k -A --authentication-file -U --user\
            -h --help' -- "$cur" ));
    fi
}
_split_longopt () 
{ 
    if [[ "$cur" == --?*=* ]]; then
        prev="${cur%%?(\\)=*}";
        cur="${cur#*=}";
        return 0;
    fi;
    return 1
}
_srv_opts () 
{ 
    local arg pkgs pkgname srvname searchsrv path count opts;
    if [[ $1 =~ .+/.* ]]; then
        pkgname=${1%%/*};
        srvname=${1#*/};
        searchsrv=1;
    else
        pkgname=${1};
    fi;
    if [[ -z ${searchsrv} ]]; then
        pkgs=(`rospack list | grep "^${pkgname}"`);
        count=0;
        opts="";
        for ((i = 0 ; i < ${#pkgs[@]} ; i=i+2 ))
        do
            if [[ -d ${pkgs[i+1]}/srv ]]; then
                opts="$opts ${pkgs[i]}/";
                pkgname=${pkgs[i]};
                count=$((count+1));
            fi;
        done;
        if [[ $count -gt 1 ]]; then
            echo $opts;
            return 0;
        fi;
    fi;
    path=`rospack find ${pkgname} 2> /dev/null`;
    if [ $? -eq 0 ] && [ -d ${path}/srv ]; then
        echo `find -L ${path}/srv -maxdepth 1 -mindepth 1 -name *.srv ! -regex ".*/[.].*" -print0 | tr '\000' '\n' | sed -e "s/.*\/\(.*\)\.srv/${pkgname}\/\1/g"`;
    fi
}
_ssh () 
{ 
    local cur prev configfile;
    local -a config;
    COMPREPLY=();
    cur=`_get_cword`;
    prev=${COMP_WORDS[COMP_CWORD-1]};
    case "$prev" in 
        -@(F|i|S))
            _filedir;
            return 0
        ;;
        -c)
            COMPREPLY=($( compgen -W '3des-cbc aes128-cbc \
				aes192-cbc aes256-cbc aes128-ctr aes192-ctr \
				aes256-ctr arcfour128 arcfour256 arcfour \
				blowfish-cbc cast128-cbc' -- "$cur" ));
            return 0
        ;;
        -c)
            COMPREPLY=($( compgen -W 'hmac-md5 hmac-sha1 \
				uma...@openssh.com hmac-ripemd160 \
				hmac-sha1-96 hmac-md5-96' -- "$cur" ));
            return 0
        ;;
        -l)
            COMPREPLY=($( compgen -u -- "$cur" ));
            return 0
        ;;
        -o)
            _ssh_options;
            return 0
        ;;
        -w)
            _available_interfaces;
            return 0
        ;;
        -b)
            COMPREPLY=($( compgen -W "$(/sbin/ifconfig | 				awk '/adr:/ {print $2}' | 				awk -F: '{print $2}' )" -- "$cur" ));
            return 0
        ;;
    esac;
    if [[ "$cur" == -F* ]]; then
        cur=${cur#-F};
        _filedir;
        COMPREPLY=("${COMPREPLY[@]/#/-F}");
        cur=-F$cur;
    else
        if [[ "$cur" == -* ]]; then
            COMPREPLY=($( compgen -W '-1 -2 -4 -6 -A -a -C -f -g -K -k -M \
			-N -n -q -s -T -t -V -v -X -v -Y -y -b -b -c -D -e -F \
			-i -L -l -m -O -o -p -R -S -w' -- "$cur" ));
        else
            set -- "${COMP_WORDS[@]}";
            while [ $# -gt 0 ]; do
                if [ "${1:0:2}" = -F ]; then
                    if [ ${#1} -gt 2 ]; then
                        configfile="$(dequote "${1:2}")";
                    else
                        shift;
                        [ "$1" ] && configfile="$(dequote "$1")";
                    fi;
                    break;
                fi;
                shift;
            done;
            _known_hosts_real -a -F "$configfile" "$cur";
            if [ $COMP_CWORD -ne 1 ]; then
                COMPREPLY=("${COMPREPLY[@]}" $( compgen -c -- "$cur" ));
            fi;
        fi;
    fi;
    return 0
}
_ssh_copy_id () 
{ 
    local cur prev;
    COMPREPLY=();
    cur=`_get_cword`;
    prev=${COMP_WORDS[COMP_CWORD-1]};
    case "$prev" in 
        -i)
            _filedir;
            return 0
        ;;
    esac;
    if [[ "$cur" == -* ]]; then
        COMPREPLY=($( compgen -W '-i' -- "$cur" ));
    else
        _known_hosts_real -a "$cur";
    fi;
    return 0
}
_ssh_options () 
{ 
    COMPREPLY=($( compgen -W 'AddressFamily BatchMode BindAddress \
		ChallengeResponseAuthentication CheckHostIP Cipher Ciphers \
		ClearAllForwardings Compression CompressionLevel \
		ConnectionAttempts ConnectTimeout ControlMaster ControlPath \
		DynamicForward EscapeChar ExitOnForwardFailure ForwardAgent \
		ForwardX11 ForwardX11Trusted GatewayPorts GlobalKnownHostsFile \
		GSSAPIAuthentication GSSAPIDelegateCredentials HashKnownHosts \
		Host HostbasedAuthentication HostKeyAlgorithms HostKeyAlias \
		HostName IdentityFile IdentitiesOnly KbdInteractiveDevices \
		LocalCommand LocalForward LogLevel MACs \
		NoHostAuthenticationForLocalhost NumberOfPasswordPrompts \
		PasswordAuthentication PermitLocalCommand Port \
		PreferredAuthentications Protocol ProxyCommand \
		PubkeyAuthentication RekeyLimit RemoteForward \
		RhostsRSAAuthentication RSAAuthentication SendEnv \
		ServerAliveInterval ServerAliveCountMax SmartcardDevice \
		StrictHostKeyChecking TCPKeepAlive Tunnel TunnelDevice \
		UsePrivilegedPort User UserKnownHostsFile VerifyHostKeyDNS \
		VisualHostKey XAuthLocation' -- "$cur" ))
}
_strace () 
{ 
    local cur prev offset i syscalls arch unistd;
    offset=0;
    for ((i=1; i <= COMP_CWORD; i++ ))
    do
        case ${COMP_WORDS[$i]} in 
            -@(o|e|p))
                i=$((i+1));
                continue
            ;;
            -*)
                continue
            ;;
        esac;
        offset=$i;
        break;
    done;
    if [ $offset -gt 0 ]; then
        _command_offset $offset;
    else
        COMPREPLY=();
        cur=`_get_cword`;
        prev=${COMP_WORDS[COMP_CWORD-1]};
        case $prev in 
            -e)
                if [[ "$cur" == *=* ]]; then
                    prev=${cur/=*/};
                    cur=${cur/*=/};
                    arch=$(command uname -m);
                    syscalls=$(awk '/^#define __NR/ {print $2}'                     /usr/include/asm/unistd.h | sed -e                     's/__NR_//');
                    if [ -z "$syscalls" ]; then
                        if [[ "$arch" =~ 86$ ]]; then
                            unistd=/usr/include/asm/unistd_32.h;
                        else
                            unistd=/usr/include/asm/unistd_64.h;
                        fi;
                        syscalls=$(awk '/^#define __NR/ {print $2}'                         $unistd | sed -e 's/__NR_//');
                    fi;
                    case $prev in 
                        trace)
                            COMPREPLY=($( compgen -W "$syscalls file process                             network signal ipc desc all none" -- "$cur"));
                            return 0
                        ;;
                    esac;
                else
                    COMPREPLY=($( compgen -S"=" -W 'trace abbrev \
                    verbose raw signal read write' -- "$cur" ));
                fi;
                return 0
            ;;
            -o)
                _filedir;
                return 0
            ;;
            -p)
                _pids;
                return 0
            ;;
            -S)
                COMPREPLY=($( compgen -W 'time calls name nothing' -- "$cur" ));
                return 0
            ;;
            -u)
                COMPREPLY=($( compgen -u -- "$cur" ));
                return 0
            ;;
        esac;
        if [[ "$cur" == -* ]]; then
            COMPREPLY=($( compgen -W '-c -d -f -ff -F -h --help -i -q \
                -r -t -tt -ttt -T -v -V -x -xx -a -e -o -O -p \
                -s -S -u -E' -- "$cur" ));
        else
            COMPREPLY=($( compgen -c -- "$cur" ));
        fi;
    fi
}
_stream () 
{ 
    local cur;
    COMPREPLY=();
    cur=`_get_cword`;
    _ImageMagick;
    if [[ "$cur" == -* ]]; then
        COMPREPLY=($( compgen -W '-authenticate -channel -colorspace \
            -compress -debug -define -density -depth -extract \
            -help -identify -interlace -interpolate -limit -list \
            -log -map -monitor -quantize -quiet -regard-warnings \
            -respect-parenthesis -sampling-factor -seed -set \
            -size -storage-type -transparent-color -verbose \
            -version -virtual-pixel' -- "$cur" ));
    else
        if [[ "$cur" == +* ]]; then
            COMPREPLY=($( compgen -W '+debug' -- "$cur" ));
        else
            _filedir;
        fi;
    fi
}
_svn () 
{ 
    local cur cmds cmdOpts pOpts mOpts rOpts qOpts nOpts optsParam opt;
    COMPREPLY=();
    cur=${COMP_WORDS[COMP_CWORD]};
    cmds='add blame annotate praise cat changelist cl checkout co cleanup';
    cmds="$cmds commit ci copy cp delete remove rm diff export help import";
    cmds="$cmds info list ls lock log merge mergeinfo mkdir move mv rename";
    cmds="$cmds propdel pdel propedit pedit propget pget proplist plist";
    cmds="$cmds propset pset resolve resolved revert status switch unlock";
    cmds="$cmds update";
    local helpOpts='--help -h';
    local specOpts="--version $helpOpts";
    optsParam="-r|--revision|--username|--password|--targets";
    optsParam="$optsParam|-x|--extensions|-m|--message|-F|--file";
    optsParam="$optsParam|--encoding|--diff-cmd|--diff3-cmd|--editor-cmd";
    optsParam="$optsParam|--old|--new|--config-dir|--config-option";
    optsParam="$optsParam|--native-eol|-l|--limit|-c|--change";
    optsParam="$optsParam|--depth|--set-depth|--with-revprop";
    optsParam="$optsParam|--changelist|--accept|--show-revs";
    local svnProps revProps allProps psCmds propCmds;
    svnProps="svn:keywords svn:executable svn:needs-lock svn:externals
	          svn:ignore svn:eol-style svn:mime-type $SVN_BASH_FILE_PROPS";
    revProps="svn:author svn:log svn:date $SVN_BASH_REV_PROPS";
    allProps=($svnProps $revProps);
    psCmds='propset|pset|ps';
    propCmds="$psCmds|propget|pget|pg|propedit|pedit|pe|propdel|pdel|pd";
    local cmd= isPropCmd= isPsCmd= isHelpCmd= nExpectArgs= isCur= i=0;
    local prev= help= prop= val= isRevProp= last='none' nargs=0 stat=;
    local options= hasRevPropOpt= hasRevisionOpt= hasRelocateOpt=;
    local acceptOpt= URL= hasReintegrateOpt=;
    for opt in "${COMP_WORDS[@]}";
    do
        [[ -n $isCur ]] && stat=$last;
        isCur=;
        [[ $i -eq $COMP_CWORD ]] && isCur=1;
        let i++;
        [ $last = 'none' ] && { 
            last='first';
            continue
        };
        if [[ $prev == @($optsParam) ]]; then
            [[ $prev = '--accept' ]] && acceptOpt=$opt;
            prev='';
            last='skip';
            continue;
        fi;
        if [[ $prev == @(<|>|>>|[12]>|[12]>>) ]]; then
            prev='';
            last='skip';
            continue;
        fi;
        prev=$opt;
        if [[ ! -n $cmd && -n $opt && ( $opt != -* || $opt == @(${specOpts// /|}) ) ]]; then
            cmd=$opt;
            [[ $cmd == @($propCmds) ]] && isPropCmd=1;
            [[ $cmd == @($psCmds) ]] && isPsCmd=1;
            [[ $cmd == @(${helpOpts// /|}) ]] && cmd='help';
            [[ $cmd = 'help' ]] && isHelpCmd=1;
            if [[ -n $isHelpCmd && -n $cmd && $cmd != 'help' && ! -n $help ]]; then
                help=$cmd;
                cmd='help';
            fi;
            last='cmd';
            continue;
        fi;
        if [[ -n $isHelpCmd && ! -n $help && -n $opt && $opt != -* ]]; then
            help=$opt;
            last='help';
            continue;
        fi;
        if [[ -n $isPropCmd && ! -n $prop && -n $opt && $opt != -* ]]; then
            prop=$opt;
            [[ $prop == @(${revProps// /|}) ]] && isRevProp=1;
            last='prop';
            continue;
        fi;
        if [[ -n $isPsCmd && -n $prop && ! -n $val && $opt != -* ]]; then
            val=$opt;
            last='val';
            continue;
        fi;
        if [[ $last != 'onlyarg' ]]; then
            case $opt in 
                -r | --revision | --revision=*)
                    hasRevisionOpt=1
                ;;
                --revprop)
                    hasRevPropOpt=1;
                    allProps=($revProps);
                    nExpectArgs=1
                ;;
                -h | --help)
                    isHelpCmd=1
                ;;
                -F | --file)
                    val='-F'
                ;;
                --relocate)
                    hasRelocateOpt=1
                ;;
                --reintegrate)
                    hasReintegrateOpt=1
                ;;
            esac;
            if [[ $opt = '--' && ! -n $isCur ]]; then
                last='onlyarg';
                continue;
            fi;
            if [[ $opt == -* ]]; then
                [[ ! -n $isCur ]] && options="$options $opt ";
                last='opt';
                continue;
            fi;
        else
            let nargs++;
            continue;
        fi;
        if [[ $cmd = 'merge' && ! -n $URL ]]; then
            URL=$opt;
        fi;
        last='arg';
        let nargs++;
    done;
    [[ -n $stat ]] || stat=$last;
    if [[ ! -n $cmd || $stat = 'cmd' ]]; then
        COMPREPLY=($( compgen -W "$cmds $specOpts" -- $cur ));
        return 0;
    fi;
    if [[ $stat = 'help' || ( -n $isHelpCmd && ! -n $help ) ]]; then
        COMPREPLY=($( compgen -W "$cmds" -- $cur ));
        return 0;
    fi;
    if [[ $cmd = 'merge' || $cmd = 'mergeinfo' ]]; then
        local here=$(_svn_info URL);
        if [[ ! -n $URL && $stat = 'arg' ]]; then
            if [[ "$here" == */branches/* ]]; then
                COMPREPLY=($(compgen -W ${here/\/branches\/*/\/trunk} -- $cur ));
                return 0;
            else
                if [[ "$here" == */trunk* ]]; then
                    COMPREPLY=($(compgen -W ${here/\/trunk*/\/branches\/} -- $cur ));
                    return 0;
                else
                    COMPREPLY=($(compgen -W $(_svn_info Root) -- $cur ));
                    return 0;
                fi;
            fi;
        else
            if [[ $URL == */branches/* && $here == */trunk* && ! -n $hasReintegrateOpt && $cur = '' && $stat = 'arg' ]]; then
                COMPREPLY=($(compgen -W '--reintegrate' -- $cur ));
                return 0;
            fi;
        fi;
    fi;
    if [[ $stat = 'skip' ]]; then
        local previous=${COMP_WORDS[COMP_CWORD-1]};
        local values= dirs= beep= exes=;
        [[ $previous = '--config-dir' ]] && dirs=1;
        [[ $previous = --*-cmd ]] && exes=1;
        [[ $previous = '--native-eol' ]] && values='LF CR CRLF';
        [[ $previous = '--limit' ]] && values='0 1 2 3 4 5 6 7 8 9';
        [[ $previous = '--revision' || $previous = '-r' ]] && values='HEAD BASE PREV COMMITTED 0 {';
        [[ $previous = '--encoding' ]] && values="latin1 utf8 $SVN_BASH_ENCODINGS";
        [[ $previous = '--extensions' || $previous = '-x' ]] && values="--unified --ignore-space-change    		        --ignore-all-space --ignore-eol-style";
        [[ $previous = '--depth' ]] && values='empty files immediates infinity';
        [[ $previous = '--set-depth' ]] && values='empty exclude files immediates infinity';
        [[ $previous = '--accept' ]] && { 
            if [[ $cmd = 'resolve' ]]; then
                values='base working mine-full theirs-full';
            else
                values='postpone base mine-full theirs-full edit launch';
            fi
        };
        [[ $previous = '--show-revs' ]] && values='merged eligible';
        if [[ $previous = '--username' ]]; then
            values="$SVN_BASH_USERNAME";
            if [[ $SVN_BASH_COMPL_EXT == *username* ]]; then
                local file=;
                for file in ~/.subversion/auth/svn.simple/*;
                do
                    if [ -r $file ]; then
                        values="$values $(_svn_read_hashfile username < $file)";
                    fi;
                done;
            fi;
            [[ ! -n "$values" ]] && beep=1;
        fi;
        [[ $previous = '--password' ]] && beep=1;
        [[ -n $values ]] && COMPREPLY=($( compgen -W "$values" -- $cur ));
        [[ -n $dirs ]] && COMPREPLY=($( compgen -o dirnames -- $cur ));
        [[ -n $exes ]] && COMPREPLY=($( compgen -c -- $cur ));
        [[ -n $beep ]] && { 
            echo -en "\a";
            COMPREPLY=('')
        };
        return 0;
    fi;
    if [[ -n $isPropCmd && ( ! -n $prop || $stat = 'prop' ) && $cur != -* ]]; then
        local choices=;
        if [[ $cur == *:* ]]; then
            local prefix=${cur%:*} suffix=${cur#*:} c=;
            for c in ${allProps[@]};
            do
                [[ $c == $prefix:* ]] && choices="$choices ${c#*:}";
            done;
            cur=$suffix;
        else
            COMPREPLY=($( compgen -W "${allProps[*]}" -- $cur ));
            [ ${#COMPREPLY[@]} -eq 1 ] && return 0;
            local seen= n=0 last= c=;
            for c in ${allProps[@]%:*};
            do
                if [[ $c == $cur* && ( ! -n $seen || $c != @($seen) ) ]]; then
                    let n++;
                    last=$c;
                    choices="$choices $c:";
                    if [[ -n $seen ]]; then
                        seen="$seen|$c*";
                    else
                        seen="$c*";
                    fi;
                fi;
            done;
            [[ $n -eq 1 ]] && choices="$last:1 $last:2";
        fi;
        COMPREPLY=($( compgen -W "$choices" -- $cur ));
        return 0;
    fi;
    if [[ -n $isRevProp && ! -n $hasRevPropOpt ]]; then
        COMPREPLY=($( compgen -W '--revprop' -- $cur ));
        return 0;
    fi;
    if [[ -n $isRevProp && -n $hasRevPropOpt && ! -n $hasRevisionOpt ]]; then
        COMPREPLY=($( compgen -W '--revision' -- $cur ));
        return 0;
    fi;
    if [[ -n $isPsCmd && -n $prop && ( ! -n $val || $stat = 'val' ) ]]; then
        local values="\' --file";
        case $prop in 
            svn:keywords)
                values="Id Rev URL Date Author Header \' $SVN_BASH_KEYWORDS"
            ;;
            svn:executable | svn:needs-lock)
                values='\\*'
            ;;
            svn:eol-style)
                values='native LF CR CRLF'
            ;;
            svn:mime-type)
                values="text/ text/plain text/html text/xml text/rtf
                       image/ image/png image/gif image/jpeg image/tiff
                       audio/ audio/midi audio/mpeg
                       video/ video/mpeg video/mp4
                       application/ application/octet-stream
                       $SVN_BASH_MIME_TYPE"
            ;;
        esac;
        COMPREPLY=($( compgen -W "$values" -- $cur ));
        [[ -n ${COMPREPLY} ]] && return 0;
    fi;
    if [[ $cmd = 'resolve' && ! -n $acceptOpt ]]; then
        COMPREPLY=($( compgen -W '--accept' -- $cur ));
        return 0;
    fi;
    case $cmd in 
        merge)
            nExpectArgs=3
        ;;
        mergeinfo)
            nExpectArgs=1
        ;;
        copy | cp | move | mv | rename | ren | export | import)
            nExpectArgs=2
        ;;
        switch | sw)
            [[ ! -n $hasRelocateOpt ]] && nExpectArgs=2
        ;;
        help | h)
            nExpectArgs=0
        ;;
        --version)
            nExpectArgs=0
        ;;
    esac;
    if [[ -n $nExpectArgs && $nargs -gt $nExpectArgs ]]; then
        echo -en "\a";
        COMPREPLY=('');
        return 0;
    fi;
    if [[ $cur != -* || $stat = 'onlyarg' ]]; then
        if [[ $SVN_BASH_COMPL_EXT == *svnstatus* ]]; then
            local status='svn status --non-interactive';
            [[ $SVN_BASH_COMPL_EXT == *recurse* ]] || status="$status --non-recursive";
            [[ $SVN_BASH_COMPL_EXT == *externals* ]] || status="$status --ignore-externals";
            local cs= files=;
            [[ -n $cur ]] && cs=$cur*;
            case $cmd in 
                st*)
                    files=$cur*
                ;;
                ci | commit | revert | di*)
                    files=$($status $cs| _svn_grcut '@([MADR!]*| M*|_M*)')
                ;;
                add)
                    files=$($status $cs| _svn_grcut '\?*')
                ;;
                unlock)
                    files=$($status $cs| _svn_grcut '@(??L*|?????[KOTB]*)')
                ;;
                resolve*)
                    files=$($status $cs| _svn_grcut '@(?C*|C*)')
                ;;
                praise | blame | ann*)
                    files=$( _svn_lls all $cur* )
                ;;
                p*)
                    if [[ $cmd == @($propCmds) && $prop == @(svn:ignore|svn:externals) ]]; then
                        files=$( _svn_lls dir . $cur* );
                    else
                        files="$( _svn_lls all $cur* )
                                   $($status $cs | _svn_grcut 'A*' )";
                    fi
                ;;
                info)
                    files="$( _svn_lls all $cur* )
                               $($status $cs | _svn_grcut 'A*' )"
                ;;
                remove | rm | del* | move | mv | rename)
                    files=$( _svn_lls all $cur* )
                ;;
                mkdir)
                    files=$( _svn_lls dir $cur* )
                ;;
                log | lock | up* | cl* | switch)
                    files=$( _svn_lls all $cur* )
                ;;
                merge)
                    files=$( _svn_lls all $cur* )
                ;;
                ls | list)
                    files=$( _svn_lls all $cur* )
                ;;
                *)
                    local fallback=1
                ;;
            esac;
            if [[ $SVN_BASH_COMPL_EXT != *recurse* ]]; then
                files="$files $( _svn_lls dir $cur* )";
            fi;
            if [[ -n $files ]]; then
                COMPREPLY=($( compgen -W "$files" -- $cur ));
                [[ -n "${COMPREPLY[*]}" ]] || COMPREPLY=('');
            else
                if [[ ! -n $fallback ]]; then
                    echo -en "\a";
                    COMPREPLY=('');
                fi;
            fi;
        fi;
        return 0;
    fi;
    pOpts="--username --password --no-auth-cache --non-interactive";
    mOpts="-m --message -F --file --encoding --force-log --with-revprop";
    rOpts="-r --revision";
    qOpts="-q --quiet";
    nOpts="-N --non-recursive --depth";
    gOpts="-g --use-merge-history";
    cmdOpts=;
    case $cmd in 
        --version)
            cmdOpts="$qOpts"
        ;;
        add)
            cmdOpts="--auto-props --no-auto-props --force --targets 		         --no-ignore --parents $nOpts $qOpts $pOpts"
        ;;
        blame | annotate | ann | praise)
            cmdOpts="$rOpts $pOpts -v --verbose --incremental --xml 		         -x --extensions --force $gOpts"
        ;;
        cat)
            cmdOpts="$rOpts $pOpts"
        ;;
        changelist | cl)
            cmdOpts="--targets $pOpts $qOpts --changelist                          -R --recursive --depth --remove"
        ;;
        checkout | co)
            cmdOpts="$rOpts $qOpts $nOpts $pOpts --ignore-externals                          --force --accept"
        ;;
        cleanup)
            cmdOpts="--diff3-cmd $pOpts"
        ;;
        commit | ci)
            cmdOpts="$mOpts $qOpts $nOpts --targets --editor-cmd $pOpts 		         --no-unlock --changelist --keep-changelists"
        ;;
        copy | cp)
            cmdOpts="$mOpts $rOpts $qOpts --editor-cmd $pOpts --parents"
        ;;
        delete | del | remove | rm)
            cmdOpts="--force $mOpts $qOpts --targets --editor-cmd $pOpts                          --keep-local"
        ;;
        diff | di)
            cmdOpts="$rOpts -x --extensions --diff-cmd --no-diff-deleted 		         $nOpts $pOpts --force --old --new --notice-ancestry 		         -c --change --summarize --changelist --xml"
        ;;
        export)
            cmdOpts="$rOpts $qOpts $pOpts $nOpts --force --native-eol                          --ignore-externals"
        ;;
        help | h | \?)
            cmdOpts=
        ;;
        import)
            cmdOpts="--auto-props --no-auto-props $mOpts $qOpts $nOpts 		         --no-ignore --editor-cmd $pOpts --force"
        ;;
        info)
            cmdOpts="$pOpts $rOpts --targets -R --recursive --depth                          --incremental --xml --changelist"
        ;;
        list | ls)
            cmdOpts="$rOpts -v --verbose -R --recursive $pOpts                          --incremental --xml --depth"
        ;;
        lock)
            cmdOpts="-m --message -F --file --encoding --force-log                          --targets --force $pOpts"
        ;;
        log)
            cmdOpts="$rOpts -v --verbose --targets $pOpts --stop-on-copy 		         --incremental --xml $qOpts -l --limit -c --change                          $gOpts --with-all-revprops --with-revprop"
        ;;
        merge)
            cmdOpts="$rOpts $nOpts $qOpts --force --dry-run --diff3-cmd 		         $pOpts --ignore-ancestry -c --change -x --extensions                          --record-only --accept --reintegrate"
        ;;
        mergeinfo)
            cmdOpts="$rOpts $pOpts --show-revs"
        ;;
        mkdir)
            cmdOpts="$mOpts $qOpts --editor-cmd $pOpts --parents"
        ;;
        move | mv | rename | ren)
            cmdOpts="$mOpts $rOpts $qOpts --force --editor-cmd $pOpts                          --parents"
        ;;
        propdel | pdel | pd)
            cmdOpts="$qOpts -R --recursive $rOpts $pOpts --changelist                          --depth";
            [[ -n $isRevProp || ! -n $prop ]] && cmdOpts="$cmdOpts --revprop"
        ;;
        propedit | pedit | pe)
            cmdOpts="--editor-cmd $pOpts $mOpts --force";
            [[ -n $isRevProp || ! -n $prop ]] && cmdOpts="$cmdOpts --revprop $rOpts"
        ;;
        propget | pget | pg)
            cmdOpts="-v --verbose -R --recursive $rOpts --strict $pOpts --changelist                          --depth --xml";
            [[ -n $isRevProp || ! -n $prop ]] && cmdOpts="$cmdOpts --revprop"
        ;;
        proplist | plist | pl)
            cmdOpts="-v --verbose -R --recursive $rOpts --revprop $qOpts 		         $pOpts --changelist --depth --xml"
        ;;
        propset | pset | ps)
            cmdOpts="$qOpts --targets -R --recursive 		         --encoding $pOpts --force --changelist --depth";
            [[ -n $isRevProp || ! -n $prop ]] && cmdOpts="$cmdOpts --revprop $rOpts";
            [[ -n $val ]] || cmdOpts="$cmdOpts -F --file"
        ;;
        resolve)
            cmdOpts="--targets -R --recursive $qOpts $pOpts --accept                          --depth"
        ;;
        resolved)
            cmdOpts="--targets -R --recursive $qOpts $pOpts --depth"
        ;;
        revert)
            cmdOpts="--targets -R --recursive $qOpts --changelist                          --depth $pOpts"
        ;;
        status | stat | st)
            cmdOpts="-u --show-updates -v --verbose $nOpts $qOpts $pOpts 		         --no-ignore --ignore-externals --incremental --xml                          --changelist"
        ;;
        switch | sw)
            cmdOpts="--relocate $rOpts $nOpts $qOpts $pOpts --diff3-cmd                          --force --accept --ignore-externals --set-depth"
        ;;
        unlock)
            cmdOpts="--targets --force $pOpts"
        ;;
        update | up)
            cmdOpts="$rOpts $nOpts $qOpts $pOpts --diff3-cmd                          --ignore-externals --force --accept --changelist                          --editor-cmd --set-depth"
        ;;
        *)

        ;;
    esac;
    [[ "$cmd" != "--version" ]] && cmdOpts="$cmdOpts $helpOpts";
    cmdOpts="$cmdOpts --config-dir --config-option";
    if [[ $acceptOpt == @(edit|launch) ]]; then
        cmdOpts=${cmdOpts/ --non-interactive / };
    fi;
    for opt in $options;
    do
        local optBase;
        case $opt in 
            --*)
                optBase=${opt/=*/}
            ;;
            -*)
                optBase=${opt:0:2}
            ;;
        esac;
        cmdOpts=" $cmdOpts ";
        cmdOpts=${cmdOpts/ ${optBase} / };
        case $optBase in 
            -v)
                cmdOpts=${cmdOpts/ --verbose / }
            ;;
            --verbose)
                cmdOpts=${cmdOpts/ -v / }
            ;;
            -N)
                cmdOpts=${cmdOpts/ --non-recursive / }
            ;;
            --non-recursive)
                cmdOpts=${cmdOpts/ -N / }
            ;;
            -R)
                cmdOpts=${cmdOpts/ --recursive / }
            ;;
            --recursive)
                cmdOpts=${cmdOpts/ -R / }
            ;;
            -x)
                cmdOpts=${cmdOpts/ --extensions / }
            ;;
            --extensions)
                cmdOpts=${cmdOpts/ -x / }
            ;;
            -q)
                cmdOpts=${cmdOpts/ --quiet / }
            ;;
            --quiet)
                cmdOpts=${cmdOpts/ -q / }
            ;;
            -h)
                cmdOpts=${cmdOpts/ --help / }
            ;;
            --help)
                cmdOpts=${cmdOpts/ -h / }
            ;;
            -l)
                cmdOpts=${cmdOpts/ --limit / }
            ;;
            --limit)
                cmdOpts=${cmdOpts/ -l / }
            ;;
            -r)
                cmdOpts=${cmdOpts/ --revision / }
            ;;
            --revision)
                cmdOpts=${cmdOpts/ -r / }
            ;;
            -c)
                cmdOpts=${cmdOpts/ --change / }
            ;;
            --change)
                cmdOpts=${cmdOpts/ -c / }
            ;;
            --auto-props)
                cmdOpts=${cmdOpts/ --no-auto-props / }
            ;;
            --no-auto-props)
                cmdOpts=${cmdOpts/ --auto-props / }
            ;;
            -g)
                cmdOpts=${cmdOpts/ --use-merge-history / }
            ;;
            --use-merge-history)
                cmdOpts=${cmdOpts/ -g / }
            ;;
            -m | --message | -F | --file)
                cmdOpts=${cmdOpts/ --message / };
                cmdOpts=${cmdOpts/ -m / };
                cmdOpts=${cmdOpts/ --file / };
                cmdOpts=${cmdOpts/ -F / }
            ;;
        esac;
        if [ $isHelpCmd ]; then
            cmdOpts=${cmdOpts/ -h / };
            cmdOpts=${cmdOpts/ --help / };
        fi;
    done;
    COMPREPLY=($( compgen -W "$cmdOpts" -- $cur ));
    return 0
}
_svn_grcut () 
{ 
    local re=$1 line= old_IFS;
    old_IFS="$IFS";
    IFS='
';
    while read -r line; do
        [[ ! -n $re || $line == $re ]] && echo "${line/????????/}";
    done;
    IFS="$old_IFS"
}
_svn_info () 
{ 
    local what=$1 line=;
    LANG=C LC_MESSAGES=C svn info --non-interactive 2> /dev/null | while read line; do
        [[ $line == *"$what: "* ]] && echo ${line#*: };
    done
}
_svn_lls () 
{ 
    local opt=$1 f=;
    shift;
    for f in "$@";
    do
        if [[ $opt == @(dir|all) && -d "$f" ]]; then
            echo "$f/";
        else
            if [[ $opt == @(file|all) ]]; then
                local dn= fn="$f";
                [[ "$f" == */* ]] && dn=${f%\/*}/ fn=${f##*\/};
                [ -f "${dn}.svn/text-base/${fn}.svn-base" ] && echo "$f";
            fi;
        fi;
    done
}
_svn_read_hashfile () 
{ 
    local tkey=$1 key= val=;
    while true; do
        read tag len;
        [ $tag = 'END' ] && break;
        [ $tag != 'K' ] && { 
            return
        };
        read -r -n $len key;
        read;
        read tag len;
        [ $tag != 'V' ] && { 
            return
        };
        read -r -n $len val;
        read;
        if [[ $key = $tkey ]]; then
            echo "$val";
            return;
        fi;
    done
}
_svnadmin () 
{ 
    local cur cmds cmdOpts optsParam opt helpCmds optBase i;
    COMPREPLY=();
    cur=${COMP_WORDS[COMP_CWORD]};
    cmds='crashtest create deltify dump help hotcopy list-dblogs \
	      list-unused-dblogs load lslocks lstxns pack recover rmlocks \
	      rmtxns setlog setrevprop setuuid upgrade verify --version';
    if [[ $COMP_CWORD -eq 1 ]]; then
        COMPREPLY=($( compgen -W "$cmds" -- $cur ));
        return 0;
    fi;
    optsParam="-r|--revision|--parent-dir|--fs-type";
    helpCmds='help|--help|h|\?';
    if [[ ${COMP_WORDS[1]} != @($helpCmds) ]] && [[ "$cur" != -* ]] || [[ ${COMP_WORDS[COMP_CWORD-1]} == @($optsParam) ]]; then
        return 0;
    fi;
    cmdOpts=;
    case ${COMP_WORDS[1]} in 
        create)
            cmdOpts="--bdb-txn-nosync --bdb-log-keep --config-dir 		         --fs-type --pre-1.4-compatible --pre-1.5-compatible"
        ;;
        deltify)
            cmdOpts="-r --revision -q --quiet"
        ;;
        dump)
            cmdOpts="-r --revision --incremental -q --quiet --deltas"
        ;;
        help | h | \?)
            cmdOpts="$cmds"
        ;;
        hotcopy)
            cmdOpts="--clean-logs"
        ;;
        load)
            cmdOpts="--ignore-uuid --force-uuid --parent-dir -q --quiet 		         --use-pre-commit-hook --use-post-commit-hook"
        ;;
        recover)
            cmdOpts="--wait"
        ;;
        rmtxns)
            cmdOpts="-q --quiet"
        ;;
        setlog)
            cmdOpts="-r --revision --bypass-hooks"
        ;;
        setrevprop)
            cmdOpts="-r --revision --use-pre-revprop-change-hook 		         --use-post-revprop-change-hook"
        ;;
        verify)
            cmdOpts="-r --revision -q --quiet"
        ;;
        *)

        ;;
    esac;
    cmdOpts="$cmdOpts --help -h";
    for ((i=2; i<=$COMP_CWORD-1; ++i ))
    do
        opt=${COMP_WORDS[$i]};
        case $opt in 
            --*)
                optBase=${opt/=*/}
            ;;
            -*)
                optBase=${opt:0:2}
            ;;
        esac;
        cmdOpts=" $cmdOpts ";
        cmdOpts=${cmdOpts/ ${optBase} / };
        case $optBase in 
            -q)
                cmdOpts=${cmdOpts/ --quiet / }
            ;;
            --quiet)
                cmdOpts=${cmdOpts/ -q / }
            ;;
            -h)
                cmdOpts=${cmdOpts/ --help / }
            ;;
            --help)
                cmdOpts=${cmdOpts/ -h / }
            ;;
            -r)
                cmdOpts=${cmdOpts/ --revision / }
            ;;
            --revision)
                cmdOpts=${cmdOpts/ -r / }
            ;;
        esac;
        if [[ $opt == @($optsParam) ]]; then
            ((++i));
        fi;
    done;
    COMPREPLY=($( compgen -W "$cmdOpts" -- $cur ));
    return 0
}
_svndumpfilter () 
{ 
    local cur cmds cmdOpts optsParam opt helpCmds optBase i;
    COMPREPLY=();
    cur=${COMP_WORDS[COMP_CWORD]};
    cmds='exclude help include --version';
    if [[ $COMP_CWORD -eq 1 ]]; then
        COMPREPLY=($( compgen -W "$cmds" -- $cur ));
        return 0;
    fi;
    optsParam="--targets";
    helpCmds='help|--help|h|\?';
    if [[ ${COMP_WORDS[1]} != @($helpCmds) ]] && [[ "$cur" != -* ]] || [[ ${COMP_WORDS[COMP_CWORD-1]} == @($optsParam) ]]; then
        return 0;
    fi;
    cmdOpts=;
    case ${COMP_WORDS[1]} in 
        exclude | include)
            cmdOpts="--drop-empty-revs --renumber-revs
		         --skip-missing-merge-sources --targets
		         --preserve-revprops --quiet"
        ;;
        help | h | \?)
            cmdOpts="$cmds"
        ;;
        *)

        ;;
    esac;
    cmdOpts="$cmdOpts --help -h";
    for ((i=2; i<=$COMP_CWORD-1; ++i ))
    do
        opt=${COMP_WORDS[$i]};
        case $opt in 
            --*)
                optBase=${opt/=*/}
            ;;
            -*)
                optBase=${opt:0:2}
            ;;
        esac;
        cmdOpts=" $cmdOpts ";
        cmdOpts=${cmdOpts/ ${optBase} / };
        case $optBase in 
            -h)
                cmdOpts=${cmdOpts/ --help / }
            ;;
            --help)
                cmdOpts=${cmdOpts/ -h / }
            ;;
        esac;
        if [[ $opt == @($optsParam) ]]; then
            ((++i));
        fi;
    done;
    COMPREPLY=($( compgen -W "$cmdOpts" -- $cur ));
    return 0
}
_svnlook () 
{ 
    local cur cmds cmdOpts optsParam opt helpCmds optBase i;
    COMPREPLY=();
    cur=${COMP_WORDS[COMP_CWORD]};
    cmds='author cat changed date diff dirs-changed help history info \
	      lock log propget proplist tree uuid youngest --version';
    if [[ $COMP_CWORD -eq 1 ]]; then
        COMPREPLY=($( compgen -W "$cmds" -- $cur ));
        return 0;
    fi;
    optsParam="-r|--revision|-t|--transaction|-l|--limit|-x|--extensions";
    helpCmds='help|--help|h|\?';
    if [[ ${COMP_WORDS[1]} != @($helpCmds) ]] && [[ "$cur" != -* ]] || [[ ${COMP_WORDS[COMP_CWORD-1]} == @($optsParam) ]]; then
        return 0;
    fi;
    cmdOpts=;
    case ${COMP_WORDS[1]} in 
        author)
            cmdOpts="-r --revision -t --transaction"
        ;;
        cat)
            cmdOpts="-r --revision -t --transaction"
        ;;
        changed)
            cmdOpts="-r --revision -t --transaction --copy-info"
        ;;
        date)
            cmdOpts="-r --revision -t --transaction"
        ;;
        diff)
            cmdOpts="-r --revision -t --transaction --diff-copy-from 		         --no-diff-added --no-diff-deleted -x --extensions"
        ;;
        dirs-changed)
            cmdOpts="-r --revision -t --transaction"
        ;;
        help | h | \?)
            cmdOpts="$cmds"
        ;;
        history)
            cmdOpts="-r --revision -l --limit --show-ids"
        ;;
        info)
            cmdOpts="-r --revision -t --transaction"
        ;;
        lock)
            cmdOpts=
        ;;
        log)
            cmdOpts="-r --revision -t --transaction"
        ;;
        propget | pget | pg)
            cmdOpts="-r --revision -t --transaction --revprop"
        ;;
        proplist | plist | pl)
            cmdOpts="-r --revision -t --transaction --revprop -v --verbose --xml"
        ;;
        tree)
            cmdOpts="-r --revision -t --transaction --full-paths -N --non-recursive --show-ids"
        ;;
        uuid)
            cmdOpts=
        ;;
        youngest)
            cmdOpts=
        ;;
        *)

        ;;
    esac;
    cmdOpts="$cmdOpts --help -h";
    for ((i=2; i<=$COMP_CWORD-1; ++i ))
    do
        opt=${COMP_WORDS[$i]};
        case $opt in 
            --*)
                optBase=${opt/=*/}
            ;;
            -*)
                optBase=${opt:0:2}
            ;;
        esac;
        cmdOpts=" $cmdOpts ";
        cmdOpts=${cmdOpts/ ${optBase} / };
        case $optBase in 
            -N)
                cmdOpts=${cmdOpts/ --non-recursive / }
            ;;
            --non-recursive)
                cmdOpts=${cmdOpts/ -N / }
            ;;
            -h)
                cmdOpts=${cmdOpts/ --help / }
            ;;
            --help)
                cmdOpts=${cmdOpts/ -h / }
            ;;
            -l)
                cmdOpts=${cmdOpts/ --limit / }
            ;;
            --limit)
                cmdOpts=${cmdOpts/ -l / }
            ;;
            -r)
                cmdOpts=${cmdOpts/ --revision / }
            ;;
            --revision)
                cmdOpts=${cmdOpts/ -r / }
            ;;
            -t)
                cmdOpts=${cmdOpts/ --transaction / }
            ;;
            --transaction)
                cmdOpts=${cmdOpts/ -t / }
            ;;
            -v)
                cmdOpts=${cmdOpts/ --verbose / }
            ;;
            --verbose)
                cmdOpts=${cmdOpts/ -v / }
            ;;
            -x)
                cmdOpts=${cmdOpts/ --extensions / }
            ;;
            --extensions)
                cmdOpts=${cmdOpts/ -x / }
            ;;
        esac;
        if [[ $opt == @($optsParam) ]]; then
            ((++i));
        fi;
    done;
    COMPREPLY=($( compgen -W "$cmdOpts" -- $cur ));
    return 0
}
_svnsync () 
{ 
    local cur cmds cmdOpts optsParam opt helpCmds optBase i;
    COMPREPLY=();
    cur=${COMP_WORDS[COMP_CWORD]};
    cmds='copy-revprops help info initialize synchronize --version';
    if [[ $COMP_CWORD -eq 1 ]]; then
        COMPREPLY=($( compgen -W "$cmds" -- $cur ));
        return 0;
    fi;
    optsParam="--config-dir|--config-option|--source-username|--source-password";
    optsParam="$optsParam|--sync-username|--sync-password";
    helpCmds='help|--help|h|\?';
    if [[ ${COMP_WORDS[1]} != @($helpCmds) ]] && [[ "$cur" != -* ]] || [[ ${COMP_WORDS[COMP_CWORD-1]} == @($optsParam) ]]; then
        return 0;
    fi;
    cmdOpts=;
    case ${COMP_WORDS[1]} in 
        copy-revprops | initialize | init | synchronize | sync)
            cmdOpts="--non-interactive --no-auth-cache --trust-server-cert 		         --source-username --source-password --sync-username 		         --sync-password --config-dir --config-option -q --quiet"
        ;;
        help | h | \?)
            cmdOpts="$cmds"
        ;;
        info)
            cmdOpts="--non-interactive --no-auth-cache --trust-server-cert 		         --source-username --source-password --sync-username 		         --sync-password --config-dir --config-option"
        ;;
        *)

        ;;
    esac;
    cmdOpts="$cmdOpts --help -h";
    for ((i=2; i<=$COMP_CWORD-1; ++i ))
    do
        opt=${COMP_WORDS[$i]};
        case $opt in 
            --*)
                optBase=${opt/=*/}
            ;;
            -*)
                optBase=${opt:0:2}
            ;;
        esac;
        cmdOpts=" $cmdOpts ";
        cmdOpts=${cmdOpts/ ${optBase} / };
        case $optBase in 
            -h)
                cmdOpts=${cmdOpts/ --help / }
            ;;
            --help)
                cmdOpts=${cmdOpts/ -h / }
            ;;
            -q)
                cmdOpts=${cmdOpts/ --quiet / }
            ;;
            --quiet)
                cmdOpts=${cmdOpts/ -q / }
            ;;
        esac;
        if [[ $opt == @($optsParam) ]]; then
            ((++i));
        fi;
    done;
    COMPREPLY=($( compgen -W "$cmdOpts" -- $cur ));
    return 0
}
_sysctl () 
{ 
    local cur;
    COMPREPLY=();
    cur=`_get_cword`;
    COMPREPLY=($( compgen -W "$(sysctl -N -a 2>/dev/null)" -- "$cur" ));
    return 0
}
_tar () 
{ 
    local cur ext regex tar untar;
    COMPREPLY=();
    cur=`_get_cword`;
    if [ $COMP_CWORD -eq 1 ]; then
        COMPREPLY=($( compgen -W 'c t x u r d A' -- "$cur" ));
        return 0;
    fi;
    case "${COMP_WORDS[1]}" in 
        ?(-)[cr]*f)
            _filedir;
            return 0
        ;;
        +([^IZzJjy])f)
            ext='t@(ar?(.@(Z|gz|bz?(2)|lz?(ma)))|gz|bz?(2)|lz?(ma))';
            regex='t\(ar\(\.\(Z\|gz\|bz2\?\|lzma\|xz\)\)\?\|gz\|bz2\?\|lzma\|xz\)'
        ;;
        *[Zz]*f)
            ext='t?(ar.)@(gz|Z)';
            regex='t\(ar\.\)\?\(gz\|Z\)'
        ;;
        *[Ijy]*f)
            ext='t?(ar.)bz?(2)';
            regex='t\(ar\.\)\?bz2\?'
        ;;
        *[J]*f)
            ext='t?(ar.)@(lz?(ma)|xz)';
            regex='t\(ar\.\)\?\(lzma\|xz\)\?'
        ;;
        *)
            _filedir;
            return 0
        ;;
    esac;
    if [[ "$COMP_LINE" == *$ext' ' ]]; then
        tar=$( echo "$COMP_LINE" | sed -e 's/^.* \([^ ]*'$regex'\) .*$/\1/' );
        untar=t${COMP_WORDS[1]//[^Izjyf]/};
        COMPREPLY=($( compgen -W "$( echo $( tar $untar $tar             2>/dev/null ) )" -- "$cur" ));
        return 0;
    fi;
    _filedir "$ext";
    return 0
}
_tcpdump () 
{ 
    local cur prev;
    COMPREPLY=();
    cur=`_get_cword`;
    prev=${COMP_WORDS[COMP_CWORD-1]};
    case "$prev" in 
        -@(r|w|F))
            _filedir;
            return 0
        ;;
        -i)
            _available_interfaces -a;
            return 0
        ;;
    esac;
    if [[ "$cur" == -* ]]; then
        COMPREPLY=($( compgen -W '-a -d -e -f -l -n -N -O -p \
            -q -R -S -t -u -v -x -C -F -i -m -r -s -T -w -E' -- "$cur" ));
    fi
}
_ufw () 
{ 
    cur=${COMP_WORDS[COMP_CWORD]};
    prev=${COMP_WORDS[COMP_CWORD-1]};
    if [ $COMP_CWORD -eq 1 ]; then
        COMPREPLY=($( compgen -W "$(_ufw_commands)" $cur ));
    else
        if [ $COMP_CWORD -eq 2 ]; then
            case "$prev" in 
                app)
                    COMPREPLY=($( compgen -W "$(_ufw_app_commands)" $cur ))
                ;;
                status)
                    COMPREPLY=($( compgen -W "$(_ufw_status_commands)" $cur ))
                ;;
                delete)
                    COMPREPLY=($( compgen -W "$(_ufw_rule_commands)" $cur ))
                ;;
                logging)
                    COMPREPLY=($( compgen -W "$(_ufw_logging_commands)" $cur ))
                ;;
                show)
                    COMPREPLY=($( compgen -W "$(_ufw_show_commands)" $cur ))
                ;;
                default)
                    COMPREPLY=($( compgen -W "$(_ufw_default_commands)" $cur ))
                ;;
            esac;
        fi;
    fi
}
_ufw_app_commands () 
{ 
    ufw --help | sed -e '1,/^Application profile commands:/d' -e '/^ [^ ]/!d' -e 's/[ \t]\+app[ \t]\+\([a-z|]\+\)[ \t]\+.*/\1/g'
}
_ufw_commands () 
{ 
    commands=$(ufw --help | sed -e '1,/^Commands:/d' -e '/^Application profile commands:/Q' -e 's/^[ \t]\+\([a-z|]\+\)[ \t]\+.*/\1/g' -e 's/|/ /g' | uniq);
    echo "$commands app"
}
_ufw_default_commands () 
{ 
    echo "allow deny reject"
}
_ufw_logging_commands () 
{ 
    echo "off on low medium high full"
}
_ufw_rule_commands () 
{ 
    echo "`_ufw_default_commands` limit"
}
_ufw_show_commands () 
{ 
    echo "raw"
}
_ufw_status_commands () 
{ 
    echo "numbered verbose"
}
_uids () 
{ 
    if type getent &>/dev/null; then
        COMPREPLY=($( compgen -W '$( getent passwd | cut -d: -f3 )' -- "$cur" ));
    else
        if type perl &>/dev/null; then
            COMPREPLY=($( compgen -W '$( perl -e '"'"'while (($uid) = (getpwent)[2]) { print $uid . "\n" }'"'"' )' -- "$cur" ));
        else
            COMPREPLY=($( compgen -W '$( cut -d: -f3 /etc/passwd )' -- "$cur" ));
        fi;
    fi
}
_umount () 
{ 
    local cur IFS='
';
    COMPREPLY=();
    cur=`_get_cword`;
    COMPREPLY=($( compgen -W '$( mount | cut -d" " -f 3 )' -- "$cur" ));
    return 0
}
_unrar () 
{ 
    local cur;
    COMPREPLY=();
    cur=`_get_cword`;
    case "$cur" in 
        -*)
            COMPREPLY=($( compgen -W '-ad -ap -av- -c- -cfg- -cl -cu \
            -dh -ep -f -idp -ierr -inul -kb -o+ -o- -ow -p -p- -r -ta \
            -tb -tn -to -u -v -ver -vp -x -x@ -y' -- "$cur" ))
        ;;
        *)
            if [ $COMP_CWORD -eq 1 ]; then
                COMPREPLY=($( compgen -W 'e l lb lt p t v vb vt x' -- "$cur" ));
            else
                _filedir '@(rar|RAR)';
            fi
        ;;
    esac;
    return 0
}
_update_alternatives () 
{ 
    local cur prev mode args i;
    COMPREPLY=();
    cur=`_get_cword`;
    prev=${COMP_WORDS[COMP_CWORD-1]};
    case "$prev" in 
        --@(altdir|admindir))
            _filedir -d;
            return 0
        ;;
        --@(help|version))
            return 0
        ;;
    esac;
    for ((i=1; i < COMP_CWORD; i++ ))
    do
        if [[ "${COMP_WORDS[i]}" == --@(install|remove|auto|display|config|remove-all) ]]; then
            mode=${COMP_WORDS[i]};
            args=$(($COMP_CWORD - i));
            break;
        fi;
    done;
    case $mode in 
        --install)
            case $args in 
                1)
                    _filedir
                ;;
                2)
                    _installed_alternatives
                ;;
                3)
                    _filedir
                ;;
            esac
        ;;
        --remove)
            case $args in 
                1)
                    _installed_alternatives
                ;;
                2)
                    _filedir
                ;;
            esac
        ;;
        --auto)
            _installed_alternatives
        ;;
        --remove-all)
            _installed_alternatives
        ;;
        --display)
            _installed_alternatives
        ;;
        --config)
            _installed_alternatives
        ;;
        *)
            COMPREPLY=($( compgen -W '--verbose --quiet --help --version \
                   --altdir --admindir' -- "$cur" ) $( compgen -W '--install --remove --auto --display \
                   --config' -- "$cur" ))
        ;;
    esac
}
_update_rc_d () 
{ 
    local cur prev sysvdir services options valid_options;
    cur=`_get_cword`;
    prev=${COMP_WORDS[COMP_CWORD-1]};
    [ -d /etc/rc.d/init.d ] && sysvdir=/etc/rc.d/init.d || sysvdir=/etc/init.d;
    services=($(echo $sysvdir/!(README*|*.sh|*.dpkg*|*.rpm@(orig|new|save))));
    services=(${services[@]#$sysvdir/});
    options=(-f -n);
    if [[ $COMP_CWORD -eq 1 || "$prev" == -* ]]; then
        valid_options=($(         echo "${COMP_WORDS[@]} ${options[@]}"         | tr " " "\n"         | sed -ne "/$( echo "${options[@]}" | sed "s/ /\\|/g" )/p"         | sort | uniq -u         ));
        COMPREPLY=($( compgen -W '${options[@]} ${services[@]}'         -X '$( echo ${COMP_WORDS[@]} | tr " " "|" )' -- "$cur" ));
    else
        if [[ "$prev" == ?($( echo ${services[@]} | tr " " "|" )) ]]; then
            COMPREPLY=($( compgen -W 'remove defaults start stop' -- "$cur" ));
        else
            if [[ "$prev" == defaults && "$cur" == [0-9] ]]; then
                COMPREPLY=(0 1 2 3 4 5 6 7 8 9);
            else
                if [[ "$prev" == defaults && "$cur" == [sk]?([0-9]) ]]; then
                    COMPREPLY=(0 1 2 3 4 5 6 7 8 9);
                else
                    if [[ "$prev" == defaults && -z "$cur" ]]; then
                        COMPREPLY=(0 1 2 3 4 5 6 7 8 9 s k);
                    else
                        if [[ "$prev" == ?(start|stop) ]]; then
                            if [[ "$cur" == [0-9] || -z "$cur" ]]; then
                                COMPREPLY=(0 1 2 3 4 5 6 7 8 9);
                            else
                                if [[ "$cur" == [0-9][0-9] ]]; then
                                    COMPREPLY=($cur);
                                else
                                    COMPREPLY=();
                                fi;
                            fi;
                        else
                            if [[ "$prev" == ?([0-9][0-9]|[0-6S]) ]]; then
                                if [[ -z "$cur" ]]; then
                                    if [[ $prev == [0-9][0-9] ]]; then
                                        COMPREPLY=(0 1 2 3 4 5 6 S);
                                    else
                                        COMPREPLY=(0 1 2 3 4 5 6 S .);
                                    fi;
                                else
                                    if [[ "$cur" == [0-6S.] ]]; then
                                        COMPREPLY=($cur);
                                    else
                                        COMPREPLY=();
                                    fi;
                                fi;
                            else
                                if [[ "$prev" == "." ]]; then
                                    COMPREPLY=($(compgen -W "start stop" -- "$cur"));
                                else
                                    COMPREPLY=();
                                fi;
                            fi;
                        fi;
                    fi;
                fi;
            fi;
        fi;
    fi;
    return 0
}
_usb_ids () 
{ 
    COMPREPLY=(${COMPREPLY[@]:-} $( compgen -W     "$( PATH="$PATH:/sbin" lsusb | awk '{print $6}' )" -- "$cur" ))
}
_user_at_host () 
{ 
    local cur;
    COMPREPLY=();
    cur=`_get_cword`;
    if [[ $cur == *@* ]]; then
        _known_hosts_real "$cur";
    else
        COMPREPLY=($( compgen -u -- "$cur" ));
    fi;
    return 0
}
_useradd () 
{ 
    local cur prev split=false;
    COMPREPLY=();
    cur=`_get_cword`;
    prev=${COMP_WORDS[COMP_CWORD-1]};
    _split_longopt && split=true;
    case "$prev" in 
        -c | --comment | -h | --help | -e | --expiredate | -f | --inactive | -k | --key | -p | --password | -u | --uid | -Z | --selinux-user)
            return 0
        ;;
        -b | --base-dir | -d | --home | -k | --skel)
            _filedir -d;
            return 0
        ;;
        -g | --gid)
            _gids;
            [ -n "$bash205" ] && COMPREPLY=("${COMPREPLY[@]}" $( compgen -g ));
            COMPREPLY=($( compgen -W '${COMPREPLY[@]}' -- "$cur" ));
            return 0
        ;;
        -G | --groups)
            [ -n "$bash205" ] && COMPREPLY=($( compgen -g -- "$cur" ));
            return 0
        ;;
        -s | --shell)
            _shells;
            return 0
        ;;
    esac;
    $split && return 0;
    if [[ "$cur" == -* ]]; then
        COMPREPLY=($( compgen -W '-b --base-dir -c --comment -d --home\
            -D --defaults -e --expiredate -f --inactive -g --gid \
            -G --groups -h --help -k --skel -K --key -l -M \
            -m --create-home -N --no-user-group -o --non-unique \
            -p --password -r --system -s --shell -u --uid \
            -U --user-group -Z --selinux-user' -- "$cur" ));
        return 0;
    fi
}
_userdel () 
{ 
    local cur;
    COMPREPLY=();
    cur=`_get_cword`;
    if [[ "$cur" == -* ]]; then
        COMPREPLY=($( compgen -W '-f --force -h --help -r --remove'             -- "$cur" ));
        return 0;
    fi;
    COMPREPLY=($( compgen -u -- "$cur" ))
}
_usergroup () 
{ 
    local IFS='
';
    cur=${cur//\\\\ / };
    if [[ $cur = *@(\\:|.)* ]] && [ -n "$bash205" ]; then
        user=${cur%%*([^:.])};
        COMPREPLY=($(compgen -P ${user/\\\\} -g -- ${cur##*[.:]}));
    else
        if [[ $cur = *:* ]] && [ -n "$bash205" ]; then
            COMPREPLY=($( compgen -g -- ${cur##*[.:]} ));
        else
            COMPREPLY=($( compgen -S : -u -- "$cur" ));
        fi;
    fi
}
_usermod () 
{ 
    local cur prev split=false;
    COMPREPLY=();
    cur=`_get_cword`;
    prev=${COMP_WORDS[COMP_CWORD-1]};
    _split_longopt && split=true;
    case "$prev" in 
        -c | --comment | -d | --home | -e | --expiredate | -f | --inactive | -h | --help | -l | --login | -p | --password | -u | --uid | -Z | --selinux-user)
            return 0
        ;;
        -g | --gid)
            _gids;
            [ -n "$bash205" ] && COMPREPLY=("${COMPREPLY[@]}" $( compgen -g ));
            COMPREPLY=($( compgen -W '${COMPREPLY[@]}' -- "$cur" ));
            return 0
        ;;
        -G | --groups)
            [ -n "$bash205" ] && COMPREPLY=($( compgen -g -- "$cur" ));
            return 0
        ;;
        -s | --shell)
            _shells;
            return 0
        ;;
    esac;
    $split && return 0;
    if [[ "$cur" == -* ]]; then
        COMPREPLY=($( compgen -W '-a --append -c --comment -d --home \
            -e --expiredate -f --inactive -g --gid -G --groups \
            -h --help -l --login -L --lock -o --non-unique \
            -p --password -s --shell -u --uid -U --unlock \
            -Z --selinux-user' -- "$cur" ));
        return 0;
    fi;
    COMPREPLY=($( compgen -u -- "$cur" ))
}
_vipw () 
{ 
    local cur prev;
    COMPREPLY=();
    cur=`_get_cword`;
    prev=${COMP_WORDS[COMP_CWORD-1]};
    case "$prev" in 
        -h | --help)
            return 0
        ;;
    esac;
    if [[ "$cur" == -* ]]; then
        COMPREPLY=($( compgen -W '-g --group -h --help -p --passwd \
            -q --quiet -s --shadow' -- "$cur" ));
        return 0;
    fi
}
_vncviewer_bootstrap () 
{ 
    local fname;
    case "$(_realcommand vncviewer)" in 
        '')
            _filedir `_get_cword`
        ;;
        *xvnc4viewer)
            fname=_xvnc4viewer
        ;;
        *tightvncviewer | *)
            fname=_tightvncviewer
        ;;
    esac;
    if [ $fname ]; then
        complete -F $fname vncviewer;
        $fname;
        unset -f _vncviewer_bootstrap;
    fi
}
_xhost () 
{ 
    local cur=`_get_cword`;
    case "$cur" in 
        +*)
            _known_hosts_real -p+ "${cur:1}"
        ;;
        -*)
            _known_hosts_real -p- "${cur:1}"
        ;;
        *)
            _known_hosts_real "$cur"
        ;;
    esac;
    return 0
}
_xmllint () 
{ 
    local cur prev;
    COMPREPLY=();
    cur=`_get_cword`;
    prev=${COMP_WORDS[COMP_CWORD-1]};
    case "$prev" in 
        -o | --output)
            _filedir;
            return 0
        ;;
        --path | --dtdvalidfpi | --maxmem | --encode | --pattern)
            return 0
        ;;
        --dtdvalid)
            _filedir dtd;
            return 0
        ;;
        --relaxng)
            _filedir rng;
            return 0
        ;;
        --schema)
            _filedir xsd;
            return 0
        ;;
        --schematron)
            _filedir sch;
            return 0
        ;;
    esac;
    if [[ "$cur" == -* ]]; then
        COMPREPLY=($( compgen -W '$( xmllint --help 2>&1 | \
            sed -ne "s/^[[:space:]]*\(--[^[:space:]:]*\).*/\1/p" ) \
            -o' -- "$cur" ));
        return 0;
    fi;
    _filedir '@(*ml|htm|svg)'
}
_xrandr () 
{ 
    local cur prev output modes;
    COMPREPLY=();
    cur=`_get_cword`;
    prev=${COMP_WORDS[COMP_CWORD-1]};
    case "$prev" in 
        --output)
            local outputs=$(xrandr|grep 'connected'|awk '{print $1}');
            COMPREPLY=($(compgen -W "$outputs" -- "$cur"));
            return 0
        ;;
        --mode)
            for ((i = 1; i < COMP_CWORD; i++ ))
            do
                if [[ "${COMP_WORDS[i]}" == "--output" ]]; then
                    output=${COMP_WORDS[i+1]};
                    break;
                fi;
            done;
            modes=$(xrandr|sed -e "1,/$output/ d"                 -e "/connected/,$ d"|awk '{print $1}');
            COMPREPLY=($( compgen -W "$modes" -- "$cur"));
            return 0
        ;;
    esac;
    case "$cur" in 
        *)
            COMPREPLY=($(compgen -W '-d -display -help -o \
                    --orientation -q --query -s --size\
                    -r --rate -v --version -x -y --screen \
                    --verbose --dryrun --prop --fb \
                    --fbmm --dpi --output --auto --mode \
                    --preferred --pos --reflect --rotate \
                    --left-of --right-of --above --below \
                    --same-as --set --off --crtc --newmode \
                    --rmmode --addmode --delmode' -- "$cur"));
            return 0
        ;;
    esac;
    return 0
}
_xvnc4viewer () 
{ 
    local cur prev;
    COMPREPLY=();
    cur=`_get_cword`;
    prev=${COMP_WORDS[COMP_CWORD-1]};
    case ${prev/#--/-} in 
        -[pP][aA][sS][sS][wW][dD] | -[pP][aA][sS][sS][wW][oO][rR][dD][fF][iI][lL][eE])
            _filedir;
            return 0
        ;;
        -[pP][rR][eE][fF][eE][rR][rR][eE][dD][eE][nN][cC][oO][dD][iI][nN][gG])
            COMPREPLY=($( compgen -W 'zrle hextile raw' -- $cur ));
            return 0
        ;;
        -[vV][iI][aA])
            _known_hosts_real "$cur";
            return 0
        ;;
    esac;
    if [[ "$cur" == -* || "$cur" == --* ]]; then
        local dash options=(AcceptClipboard AutoSelect DebugDelay display DotWhenNoCursor FullColor FullColour FullScreen geometry help listen Log LowColourLevel MenuKey name Parent passwd PasswordFile PointerEventInterval PreferredEncoding SendClipboard SendPrimary Shared UseLocalCursor via ViewOnly WMDecorationHeight WMDecorationWidth ZlibLevel);
        [[ "$cur" == --* ]] && dash=-- || dash=-;
        if shopt nocasematch 2> /dev/null | grep --color=auto -q ^nocasematch; then
            local option oldNoCaseMatch=$(shopt -p nocasematch);
            shopt -s nocasematch;
            COMPREPLY=($( for option in "${options[@]}"; do
                [[ $dash$option == "$cur"* ]] && echo $dash$option
            done ));
            eval "$oldNoCaseMatch" 2> /dev/null;
        else
            COMPREPLY=($( compgen -W "$(
                echo ${options[@]/#/$dash} | tr [:upper:] [:lower:]
                )" -- "$(echo "$cur" | tr [:upper:] [:lower:])" ));
        fi;
    else
        _known_hosts_real "$cur";
    fi
}
_xz () 
{ 
    COMPREPLY=();
    local cur=`_get_cword`;
    local prev=${COMP_WORDS[COMP_CWORD-1]};
    if [[ "$cur" == -* ]]; then
        COMPREPLY=($( compgen -W '-z --compress -d --decompress \
            -t --test -l --list -k --keep -f --force -c --stdout \
            -S --suffix --files --files0 -F --format -C --check \
            -0 -1 -2 -3 -4 -5 -6 -7 -8 -9 -M --memory --lzma1 \
            --lzma2 --x86 --powerpc --ia64 --arm --armthumb \
            --sparc --delta -q --quiet -v --verbose -h --help \
            -H --long-help -V --version' -- "$cur" ));
        return 0;
    fi;
    local split=false;
    _split_longopt && split=true;
    local xspec="*.@(xz|lzma)";
    case "$prev" in 
        -@(!(-*)[dlt]*|-decompress|-list|-test))
            xspec="!"$xspec
        ;;
        --files | --files0)
            _filedir;
            return 0
        ;;
        -C | --check)
            COMPREPLY=($( compgen -W 'crc32 crc64 sha256' -- "$cur" ));
            return 0
        ;;
        -F | --format)
            COMPREPLY=($( compgen -W 'auto xz lzma raw' -- "$cur" ));
            return 0
        ;;
        -M | --memory | -S | --suffix | --delta | --lzma1 | --lzma2)
            return 0
        ;;
        -h | --help | -H | --long-help | -V | --version)
            return 0
        ;;
    esac;
    $split && return 0;
    _expand || return 0;
    local IFS='	
';
    COMPREPLY=($( compgen -f -X "$xspec" -- "$cur" ) $( compgen -d -- "$cur" ))
}
_xzdec () 
{ 
    COMPREPLY=();
    local cur=`_get_cword`;
    local prev=${COMP_WORDS[COMP_CWORD-1]};
    if [[ "$cur" == -* ]]; then
        COMPREPLY=($( compgen -W '-M --memory -h --help -V --version'             -- "$cur" ));
        return 0;
    fi;
    local split=false;
    _split_longopt && split=true;
    case "$prev" in 
        -M | --memory)
            return 0
        ;;
        -h | --help | -V | --version)
            return 0
        ;;
    esac;
    $split && return 0;
    _filedir xz
}
command_not_found_handle () 
{ 
    if [ -x /usr/lib/command-not-found ]; then
        /usr/bin/python /usr/lib/command-not-found -- $1;
        return $?;
    else
        if [ -x /usr/share/command-not-found ]; then
            /usr/bin/python /usr/share/command-not-found -- $1;
            return $?;
        else
            return 127;
        fi;
    fi
}
dequote () 
{ 
    eval echo "$1" 2> /dev/null
}
get_entries () 
{ 
    local IFS='
';
    [ -r ${prefix:-}CVS/Entries ] && entries=$(cut -d/ -f2 -s ${prefix:-}CVS/Entries)
}
get_modules () 
{ 
    if [ -n "$prefix" ]; then
        COMPREPLY=($( command ls -d ${cvsroot}/${prefix}/!(CVSROOT) ));
    else
        COMPREPLY=($( command ls -d ${cvsroot}/!(CVSROOT) ));
    fi
}
quote () 
{ 
    echo \'${1//\'/\'\\\'\'}\'
}
quote_readline () 
{ 
    if [ -n "$bash4" ]; then
        echo "${1}";
        return;
    fi;
    local t="${1//\\/\\\\}";
    echo \'${t//\'/\'\\\'\'}\'
}
rosawesome () 
{ 
    alias megamaid=rosrecord;
    alias suck2blow=rosplay;
    alias botherder=roscore
}
roscd () 
{ 
    local rosvals;
    if [[ $1 = "--help" ]] | [[ $# -gt 1 ]]; then
        echo -e "usage: roscd package\n\nJump to target package.";
        return 0;
    fi;
    if [ -z $1 ]; then
        if [ -z $ROS_WORKSPACE ]; then
            echo -e "No ROS_WORKSPACE set.  Please set ROS_WORKSPACE to use roscd with no arguments.";
            return 1;
        fi;
        cd ${ROS_WORKSPACE};
        return 0;
    fi;
    _ros_decode_path $1 forceeval;
    if [ $? != 0 ]; then
        echo "roscd: No such package/stack '$1'";
        return 1;
    else
        if [ -z $rosvals ]; then
            if [ -z $ROS_WORKSPACE ]; then
                echo -e "No ROS_WORKSPACE set.  Please set ROS_WORKSPACE to use roscd with no arguments.";
                return 1;
            fi;
            cd ${ROS_WORKSPACE};
            return 0;
        else
            cd ${rosvals[1]}${rosvals[2]}${rosvals[3]};
            return 0;
        fi;
    fi
}
roscp () 
{ 
    local arg;
    if [[ $1 = "--help" ]] | [[ $# -ne 3 ]]; then
        echo -e "usage: roscp package filename target\n\nCopy a file from a package to target location.";
        return 0;
    fi;
    _roscmd ${1} ${2};
    cp -i ${arg} ${3}
}
rosd () 
{ 
    if [[ $1 = "--help" ]]; then
        echo -e "usage: rosd\n\nDisplays the list of currently remembered directories with indexes.";
        return 0;
    fi;
    let count=0;
    for items in `dirs`;
    do
        echo $count $items;
        let count=$((count+1));
    done
}
rosed () 
{ 
    local arg;
    if [[ $1 = "--help" ]]; then
        echo -e "usage: rossed [package] [file]\n\nEdit a file within a package.";
        return 0;
    fi;
    _roscmd ${1} ${2};
    if [[ -n ${arg} ]]; then
        if [[ -z $EDITOR ]]; then
            vim ${arg};
        else
            $EDITOR ${arg};
        fi;
    fi
}
rosls () 
{ 
    local rosvals;
    if [[ $1 = "--help" ]]; then
        echo -e "usage: rosls [package]\n\nLists contents of a package directory.";
        return 0;
    fi;
    _ros_decode_path $1 forceeval;
    ls --color=auto ${rosvals[1]}${rosvals[2]}${rosvals[3]} $2
}
rospd () 
{ 
    if [[ $1 = "--help" ]]; then
        echo -e "usage: rospd\n\nLike pushd, also accepts indexes from rosd.";
        return 0;
    fi;
    if _is_integer $1; then
        pushd +$1 > /dev/null;
    else
        local rosvals;
        _ros_decode_path $1 forceeval;
        pushd ${rosvals[1]}${rosvals[2]}${rosvals[3]} > /dev/null;
    fi;
    rosd
}
rospython () 
{ 
    local pkgname;
    if [[ $1 = "--help" ]]; then
        echo -e "usage: rospython [package] \n\nRun python loading package manifest first.";
        return 0;
    fi;
    if [[ -z $1 ]]; then
        if [[ -f ./manifest.xml ]]; then
            pkgname=`basename \`pwd\``;
            python -i -c "import roslib; roslib.load_manifest('$pkgname')";
        else
            python;
        fi;
    else
        python -i -c "import roslib; roslib.load_manifest('$1')";
    fi
}
rossetip () 
{ 
    export ROS_IP=`LANGUAGE=en LANG=C ifconfig | grep inet\  | grep -v 127.0.0.1 | sed 's/.*inet addr:\([0-9\.]*\).*/\1/' | head -1`;
    export ROS_HOSTNAME=$ROS_IP;
    echo -e "\e[1;31mset ROS_IP and ROS_HOSTNAME to $ROS_IP\e[m"
}
rossetlocal () 
{ 
    export ROS_MASTER_URI=http://localhost:11311;
    echo -e "\e[1;31mset ROS_MASTER_URI to $ROS_MASTER_URI\e[m"
}
rossetpr2 () 
{ 
    rossetrobot 10.68.0.1;
    rossetip
}
rossetrobot () 
{ 
    local hostname=${1-"pr1012"};
    local ros_port=${2-"11311"};
    export ROS_MASTER_URI=http://$hostname:$ros_port;
    echo -e "\e[1;31mset ROS_MASTER_URI to $ROS_MASTER_URI\e[m"
}
set_prefix () 
{ 
    [ -z ${prefix:-} ] || prefix=${cur%/*}/;
    [ -r ${prefix:-}CVS/Entries ] || prefix=""
}

2012年11月20日火曜日 12時15分40秒 UTC+9 垣内(JSK):

>> >> >> >> >>>> > このグループに投稿するには、rtm-ros-robo...@googlegroups.com
>> >> >> >> >>>> > にメールを送信してください。
>> >> >> >> >>>> >
>> >> >> >> >>>> > このグループから退会するには、rtm-ros-robotics+unsubscribe@googlegroups.com


>> >> >> >> >>>> > にメールを送信してください。
>> >> >> >> >>>> >
>> >> >> >> >>>> > 詳細については、http://groups.google.com/group/rtm-ros-robotics?hl=ja
>> >> >> >> >>>> > からこのグループにアクセスしてください。
>> >> >> >> >>>
>> >> >> >> >>> --
>> >> >> >> >>> このメールは Google グループのグループ「rtm-ros-robotics」の登録者に送られています。
>> >> >> >> >>>
>> >> >> >> >>>
>> >> >> >> >>>
>> >> >> >> >>>
>> >> >> >> >>>
>> >> >> >> >>> このディスカッションをウェブ上で閲覧するには、https://groups.google.com/d/msg/rtm-ros-robotics/-/96iaEyXPA24J
>> >> >> >> >>> にアクセスしてください。

>> >> >> >> >>> このグループに投稿するには、rtm-ros-robo...@googlegroups.com
>> >> >> >> >>> にメールを送信してください。
>> >> >> >> >>> このグループから退会するには、rtm-ros-robotics+unsubscribe@googlegroups.com


>> >> >> >> >>> にメールを送信してください。
>> >> >> >> >>> 詳細については、http://groups.google.com/group/rtm-ros-robotics?hl=ja
>> >> >> >> >>> からこのグループにアクセスしてください。
>> >> >> >> >
>> >> >> >> > --
>> >> >> >> > このメールは Google グループのグループ「rtm-ros-robotics」の登録者に送られています。
>> >> >> >> >
>> >> >> >> >
>> >> >> >> >
>> >> >> >> >
>> >> >> >> > このディスカッションをウェブ上で閲覧するには、https://groups.google.com/d/msg/rtm-ros-robotics/-/rj7mfpLznvAJ
>> >> >> >> > にアクセスしてください。
>> >> >> >> >

>> >> >> >> > このグループに投稿するには、rtm-ros-robo...@googlegroups.com にメールを送信してください。
>> >> >> >> > このグループから退会するには、rtm-ros-robotics+unsubscribe@googlegroups.com


>> >> >> >> > にメールを送信してください。
>> >> >> >> > 詳細については、http://groups.google.com/group/rtm-ros-robotics?hl=ja
>> >> >> >> > からこのグループにアクセスしてください。
>> >> >> >
>> >> >> > --
>> >> >> > このメールは Google グループのグループ「rtm-ros-robotics」の登録者に送られています。
>> >> >> >
>> >> >> >
>> >> >> >
>> >> >> > このディスカッションをウェブ上で閲覧するには、https://groups.google.com/d/msg/rtm-ros-robotics/-/PLHJC3epc34J
>> >> >> > にアクセスしてください。
>> >> >> >

>> >> >> > このグループに投稿するには、rtm-ros-robo...@googlegroups.com にメールを送信してください。
>> >> >> > このグループから退会するには、rtm-ros-robotics+unsubscribe@googlegroups.com


>> >> >> > にメールを送信してください。
>> >> >> > 詳細については、http://groups.google.com/group/rtm-ros-robotics?hl=ja
>> >> >> > からこのグループにアクセスしてください。
>> >> >
>> >> > --
>> >> > このメールは Google グループのグループ「rtm-ros-robotics」の登録者に送られています。
>> >> >
>> >> >
>> >> > このディスカッションをウェブ上で閲覧するには、https://groups.google.com/d/msg/rtm-ros-robotics/-/LHsPRKE7WzgJ
>> >> > にアクセスしてください。
>> >> >

>> >> > このグループに投稿するには、rtm-ros-robo...@googlegroups.com にメールを送信してください。
>> >> > このグループから退会するには、rtm-ros-robotics+unsubscribe@googlegroups.com


>> >> > にメールを送信してください。
>> >> > 詳細については、http://groups.google.com/group/rtm-ros-robotics?hl=ja
>> >> > からこのグループにアクセスしてください。
>> >
>> > --
>> > このメールは Google グループのグループ「rtm-ros-robotics」の登録者に送られています。
>> >
>> > このディスカッションをウェブ上で閲覧するには、https://groups.google.com/d/msg/rtm-ros-robotics/-/zDpkevrJc3cJ
>> > にアクセスしてください。
>> >

>> > このグループに投稿するには、rtm-ros-robo...@googlegroups.com にメールを送信してください。
>> > このグループから退会するには、rtm-ros-robotics+unsubscribe@googlegroups.com


>> > にメールを送信してください。
>> > 詳細については、http://groups.google.com/group/rtm-ros-robotics?hl=ja
>> > からこのグループにアクセスしてください。
>
> --
> このメールは Google グループのグループ「rtm-ros-robotics」の登録者に送られています。
> このディスカッションをウェブ上で閲覧するには、https://groups.google.com/d/msg/rtm-ros-robotics/-/ix0XVZ9irxQJ
> にアクセスしてください。
>

> このグループに投稿するには、rtm-ros-robo...@googlegroups.com にメールを送信してください。
> このグループから退会するには、rtm-ros-robotics+unsubscribe@googlegroups.com にメールを送信してください。
> 詳細については、http://groups.google.com/group/rtm-ros-robotics?hl=ja
> からこのグループにアクセスしてください。

Yohei Kakiuchi

unread,
Nov 20, 2012, 5:12:30 AM11/20/12
to rtm-ros-...@googlegroups.com
ホームディレクトリの直下の、camera_umd には、uvc_cameraがありますか?
あるなら、camera_umdのディレクトリを~/ros/fuerte に移動させればとりあえずは
つかえるはずです。
rosmake roseus_tutorials します。

ros/fuerte の下でgit cloneできない理由は分かりません。
ros/fuerte で ls -a するとどうなりますか?

2012/11/20 yuto inagaki <yuto.i...@gmail.com>:
> ...
>
> [クリップしたメッセージ]

yuto inagaki

unread,
Nov 20, 2012, 6:12:44 AM11/20/12
to rtm-ros-...@googlegroups.com
mechuser@UoT-IST-Ub:~/ros/fuerte$ ls -a
#.rosinstall#    commandHistory.txt        stacks
.                http:                     tum-ros-pkg
..               jsk-ros-pkg               turtlebot
.rosinstall      multimaster_experimental  ua-ros-pkg
.rosinstall.bak  ros-pkg-git               umd-ros-pkg
.rosinstall~     rtm-ros-robotics          webots-ros-pkg
camera_umd       setup.bash                wg-ros-pkg-cturtle
ccny-vision      setup.sh
cmu-ros-pkg      setup.zsh
mechuser@UoT-IST-Ub:~/ros/fuerte$ 
となっており
mechuser@UoT-IST-Ub:~/ros/fuerte/camera_umd$ ls
CMakeLists.txt  jpeg_streamer  uvc_camera
Makefile        stack.xml      uvc_stereo
mechuser@UoT-IST-Ub:~/ros/fuerte/camera_umd$ 

となっております。

ホームディレクトリを移動し、コンパイルをしたところ、
最後のようになりました。

また、念のため、カメラの実行をしましたが、
mechuser@UoT-IST-Ub:~$ roslaunch roseus_tutorials usb-camera.launch 
... logging to /home/mechuser/.ros/log/1b11377a-3301-11e2-bf52-0022fb92479e/roslaunch-UoT-IST-Ub-13067.log
Checking log directory for disk usage. This may take awhile.
Press Ctrl-C to interrupt
Done checking log file disk usage. Usage is <1GB.

started roslaunch server http://UoT-IST-Ub:44787/
process[image_proc-2]: started with pid [13087]
[ WARN] [1353409104.691137481]: Started in the global namespace! This is probably wrong. Start image_proc in the camera namespace.
Example command-line usage:

となって、未だにuvc_cameraがないようです。

rosmake roseus_tutorialsでエラーが出てしまいました。

mechuser@UoT-IST-Ub:~/ros/fuerte$ rosmake roseus_tutorials 
[ rosmake ] rosmake starting...                                           
[ rosmake ] Packages requested are: ['roseus_tutorials']                  
[ rosmake ] Logging to directory /home/mechuser/.ros/rosmake/rosmake_output-20121120-195918
[ rosmake ] Expanded args ['roseus_tutorials'] to:
['roseus_tutorials']   
[rosmake-0] Starting >>> roslang [ make ]                                 
[rosmake-0] Finished <<< roslang  No Makefile in package roslang          
[rosmake-0] Starting >>> roscpp [ make ]                                  
[rosmake-0] Finished <<< roscpp  No Makefile in package roscpp            
[rosmake-0] Starting >>> rospack [ make ]                                 
[rosmake-0] Finished <<< rospack  No Makefile in package rospack          
[rosmake-0] Starting >>> euslisp [ make ]                                 
[rosmake-1] Starting >>> rospy [ make ]                                   
[rosmake-1] Finished <<< rospy  No Makefile in package rospy              
[rosmake-1] Starting >>> rostest [ make ]                                 
[rosmake-1] Finished <<< rostest  No Makefile in package rostest          
[rosmake-1] Starting >>> actionlib_msgs [ make ]                          
[rosmake-1] Finished <<< actionlib_msgs  No Makefile in package actionlib_msgs
[rosmake-1] Starting >>> actionlib [ make ]                               
[rosmake-1] Finished <<< actionlib  No Makefile in package actionlib      
[rosmake-1] Starting >>> geometry_msgs [ make ]                           
[rosmake-1] Finished <<< geometry_msgs  No Makefile in package geometry_msgs
[rosmake-1] Starting >>> std_msgs [ make ]                                
[rosmake-1] Finished <<< std_msgs  No Makefile in package std_msgs        
[rosmake-1] Starting >>> visualization_msgs [ make ]                      
[rosmake-1] Finished <<< visualization_msgs  No Makefile in package visualization_msgs
[rosmake-1] Starting >>> bullet [ make ]                                  
[rosmake-1] Finished <<< bullet ROS_NOBUILD in package bullet             
[rosmake-1] Starting >>> sensor_msgs [ make ]                             
[rosmake-1] Finished <<< sensor_msgs  No Makefile in package sensor_msgs  
[rosmake-1] Starting >>> rosconsole [ make ]                              
[rosmake-1] Finished <<< rosconsole  No Makefile in package rosconsole    
[rosmake-1] Starting >>> angles [ make ]                                  
[rosmake-1] Finished <<< angles ROS_NOBUILD in package angles             
[rosmake-1] Starting >>> roswtf [ make ]                                  
[rosmake-1] Finished <<< roswtf  No Makefile in package roswtf            
[rosmake-1] Starting >>> message_filters [ make ]                         
[rosmake-1] Finished <<< message_filters  No Makefile in package message_filters
[rosmake-1] Starting >>> tf [ make ]                                      
[rosmake-1] Finished <<< tf ROS_NOBUILD in package tf                     
[rosmake-1] Starting >>> std_srvs [ make ]                                
[rosmake-1] Finished <<< std_srvs  No Makefile in package std_srvs        
[rosmake-1] Starting >>> roslib [ make ]                                  
[rosmake-1] Finished <<< roslib  No Makefile in package roslib            
[rosmake-1] Starting >>> actionlib_tutorials [ make ]                     
[rosmake-1] Finished <<< actionlib_tutorials ROS_NOBUILD in package actionlib_tutorials
[rosmake-1] Starting >>> artoolkit [ make ]                               
[rosmake-1] Finished <<< artoolkit [PASS] [ 0.02 seconds ]                
[rosmake-1] Starting >>> resource_retriever [ make ]                      
[rosmake-1] Finished <<< resource_retriever ROS_NOBUILD in package resource_retriever
[rosmake-1] Starting >>> opencv2 [ make ]                                 
[rosmake-1] Finished <<< opencv2 ROS_NOBUILD in package opencv2           
[rosmake-1] Starting >>> rosbuild [ make ]                                
[rosmake-1] Finished <<< rosbuild  No Makefile in package rosbuild        
[rosmake-1] Starting >>> pluginlib [ make ]                               
[rosmake-1] Finished <<< pluginlib ROS_NOBUILD in package pluginlib       
[rosmake-1] Starting >>> image_transport [ make ]                         
[rosmake-1] Finished <<< image_transport ROS_NOBUILD in package image_transport
[rosmake-1] Starting >>> cv_bridge [ make ]                               
[rosmake-1] Finished <<< cv_bridge ROS_NOBUILD in package cv_bridge       
[rosmake-1] Starting >>> ar_pose [ make ]                                 
[rosmake-0] Finished <<< euslisp [PASS] [ 1.46 seconds ]                  
[rosmake-0] Starting >>> roseus [ make ]                                  
[rosmake-1] Finished <<< ar_pose [PASS] [ 1.98 seconds ]                  
[rosmake-1] Starting >>> nmpt [ make ]                                    
[ rosmake ] Last 40 linesseus: 2.7 sec ] [ ... [ 2 Active 29/68 Complete ]
{-------------------------------------------------------------------------------
  [rosbuild] Couldn't find source file src/nmpt/ImagePatch2.cpp; assuming that it is in /home/mechuser/ros/fuerte/ua-ros-pkg/ua_vision/nmpt and will be generated later
  [rosbuild] Couldn't find source file src/nmpt/ImagePatchPyramid.cpp; assuming that it is in /home/mechuser/ros/fuerte/ua-ros-pkg/ua_vision/nmpt and will be generated later
  [rosbuild] Couldn't find source file src/nmpt/InternalMotionModel.cpp; assuming that it is in /home/mechuser/ros/fuerte/ua-ros-pkg/ua_vision/nmpt and will be generated later
  [rosbuild] Couldn't find source file src/nmpt/KF.cpp; assuming that it is in /home/mechuser/ros/fuerte/ua-ros-pkg/ua_vision/nmpt and will be generated later
  [rosbuild] Couldn't find source file src/nmpt/KFPointTracker.cpp; assuming that it is in /home/mechuser/ros/fuerte/ua-ros-pkg/ua_vision/nmpt and will be generated later
  [rosbuild] Couldn't find source file src/nmpt/LQR.cpp; assuming that it is in /home/mechuser/ros/fuerte/ua-ros-pkg/ua_vision/nmpt and will be generated later
  [rosbuild] Couldn't find source file src/nmpt/LQRPointTracker.cpp; assuming that it is in /home/mechuser/ros/fuerte/ua-ros-pkg/ua_vision/nmpt and will be generated later
  [rosbuild] Couldn't find source file src/nmpt/MatrixKalmanFilter.cpp; assuming that it is in /home/mechuser/ros/fuerte/ua-ros-pkg/ua_vision/nmpt and will be generated later
  [rosbuild] Couldn't find source file src/nmpt/MIPOMDP.cpp; assuming that it is in /home/mechuser/ros/fuerte/ua-ros-pkg/ua_vision/nmpt and will be generated later
  [rosbuild] Couldn't find source file src/nmpt/MultinomialObservationModel.cpp; assuming that it is in /home/mechuser/ros/fuerte/ua-ros-pkg/ua_vision/nmpt and will be generated later
  [rosbuild] Couldn't find source file src/nmpt/MultiObjectTrackingState.cpp; assuming that it is in /home/mechuser/ros/fuerte/ua-ros-pkg/ua_vision/nmpt and will be generated later
  [rosbuild] Couldn't find source file src/nmpt/NMPTUtils.cpp; assuming that it is in /home/mechuser/ros/fuerte/ua-ros-pkg/ua_vision/nmpt and will be generated later
  [rosbuild] Couldn't find source file src/nmpt/ObjectDetector.cpp; assuming that it is in /home/mechuser/ros/fuerte/ua-ros-pkg/ua_vision/nmpt and will be generated later
  [rosbuild] Couldn't find source file src/nmpt/OpenCV2BoxFilter.cpp; assuming that it is in /home/mechuser/ros/fuerte/ua-ros-pkg/ua_vision/nmpt and will be generated later
  [rosbuild] Couldn't find source file src/nmpt/OpenCVHaarDetector.cpp; assuming that it is in /home/mechuser/ros/fuerte/ua-ros-pkg/ua_vision/nmpt and will be generated later
  [rosbuild] Couldn't find source file src/nmpt/OpenLoopPolicies.cpp; assuming that it is in /home/mechuser/ros/fuerte/ua-ros-pkg/ua_vision/nmpt and will be generated later
  [rosbuild] Couldn't find source file src/nmpt/PatchDataset.cpp; assuming that it is in /home/mechuser/ros/fuerte/ua-ros-pkg/ua_vision/nmpt and will be generated later
  [rosbuild] Couldn't find source file src/nmpt/PatchDataset2.cpp; assuming that it is in /home/mechuser/ros/fuerte/ua-ros-pkg/ua_vision/nmpt and will be generated later
  [rosbuild] Couldn't find source file src/nmpt/PatchList.cpp; assuming that it is in /home/mechuser/ros/fuerte/ua-ros-pkg/ua_vision/nmpt and will be generated later
  [rosbuild] Couldn't find source file src/nmpt/PatchList2.cpp; assuming that it is in /home/mechuser/ros/fuerte/ua-ros-pkg/ua_vision/nmpt and will be generated later
  [rosbuild] Couldn't find source file src/nmpt/StructTypes.cpp; assuming that it is in /home/mechuser/ros/fuerte/ua-ros-pkg/ua_vision/nmpt and will be generated later
  [rosbuild] Couldn't find source file src/nmpt/ChooseSaccadeTargets.cpp; assuming that it is in /home/mechuser/ros/fuerte/ua-ros-pkg/ua_vision/nmpt and will be generated later
  [rosbuild] Couldn't find source file src/nmpt/CVPRTestSpeed.cpp; assuming that it is in /home/mechuser/ros/fuerte/ua-ros-pkg/ua_vision/nmpt and will be generated later
  [rosbuild] Couldn't find source file src/nmpt/CVPRTrainModels.cpp; assuming that it is in /home/mechuser/ros/fuerte/ua-ros-pkg/ua_vision/nmpt and will be generated later
  [rosbuild] Couldn't find source file /home/mechuser/ros/fuerte/ua-ros-pkg/ua_vision/nmpt/src/nmpt/EstimateInternalMotion.cpp; assuming that it is in /home/mechuser/ros/fuerte/ua-ros-pkg/ua_vision/nmpt and will be generated later
  [rosbuild] Couldn't find source file src/nmpt/FastSUN.cpp; assuming that it is in /home/mechuser/ros/fuerte/ua-ros-pkg/ua_vision/nmpt and will be generated later
  [rosbuild] Couldn't find source file src/nmpt/FastSUNImage.cpp; assuming that it is in /home/mechuser/ros/fuerte/ua-ros-pkg/ua_vision/nmpt and will be generated later
  [rosbuild] Couldn't find source file src/nmpt/FoveatedFaceTracker.cpp; assuming that it is in /home/mechuser/ros/fuerte/ua-ros-pkg/ua_vision/nmpt and will be generated later
  [rosbuild] Couldn't find source file src/nmpt/FoveatedFaceTrackerImage.cpp; assuming that it is in /home/mechuser/ros/fuerte/ua-ros-pkg/ua_vision/nmpt and will be generated later
  [rosbuild] Couldn't find source file src/nmpt/SimpleFaceTracker.cpp; assuming that it is in /home/mechuser/ros/fuerte/ua-ros-pkg/ua_vision/nmpt and will be generated later
  [rosbuild] Couldn't find source file src/nmpt/SimpleSalienceExample.cpp; assuming that it is in /home/mechuser/ros/fuerte/ua-ros-pkg/ua_vision/nmpt and will be generated later
  [rosbuild] Couldn't find source file src/nmpt/TrainNarrowFOVModel.cpp; assuming that it is in /home/mechuser/ros/fuerte/ua-ros-pkg/ua_vision/nmpt and will be generated later
  -- Configuring done
  CMake Error in CMakeLists.txt:
    Cannot find source file "CVPRTestSpeed.cpp".  Tried extensions .c .C .c++
    .cc .cpp .cxx .m .M .mm .h .hh .h++ .hm .hpp .hxx .in .txx
  
  
  -- Build files have been written to: /home/mechuser/ros/fuerte/ua-ros-pkg/ua_vision/nmpt/build
-------------------------------------------------------------------------------}
[ rosmake ] Output from build of package nmpt written to:
[ rosmake ]    /home/mechuser/.ros/rosmake/rosmake_output-20121120-195918/nmpt/build_output.log
[rosmake-1] Finished <<< nmpt [FAIL] [ 1.46 seconds ]                     
[ rosmake ] Halting due to failure in package nmpt. 
[ rosmake ] Waiting for other threads to complete.
[rosmake-0] Finished <<< roseus [PASS] [ 27.42 seconds ]                  
[ rosmake ] Results:                                                      
[ rosmake ] Built 31 packages with 1 failures.                            
[ rosmake ] Summary output to directory                                   
[ rosmake ] /home/mechuser/.ros/rosmake/rosmake_output-20121120-195918    
mechuser@UoT-IST-Ub:~/ros/fuerte$ 


2012年11月20日火曜日 19時12分33秒 UTC+9 垣内(JSK):

Yohei Kakiuchi

unread,
Nov 20, 2012, 6:27:21 AM11/20/12
to rtm-ros-...@googlegroups.com
nmpt がコンパイルできていないようです。どうやら、NMPT.zipの場所が変わってしまったようです。
rosmake -k roseus_tutorialsとするとどうでしょうか?

これでも、uvc_cameraがコンパイルできないようなら、
rosmake uvc_camera としてみてください。

2012/11/20 yuto inagaki <yuto.i...@gmail.com>:
> --
> このメールは Google グループのグループ「rtm-ros-robotics」の登録者に送られています。
> このディスカッションをウェブ上で閲覧するには、https://groups.google.com/d/msg/rtm-ros-robotics/-/T1_e02_yFu4J
> にアクセスしてください。
> このグループに投稿するには、rtm-ros-...@googlegroups.com にメールを送信してください。
> このグループから退会するには、rtm-ros-roboti...@googlegroups.com にメールを送信してください。
> 詳細については、http://groups.google.com/group/rtm-ros-robotics?hl=ja
> からこのグループにアクセスしてください。

yuto inagaki

unread,
Nov 20, 2012, 7:03:31 AM11/20/12
to rtm-ros-...@googlegroups.com
rosmake -k roseus_tutorialsは3つのエラーを残したまま
uvc_cameraができているの分からなかったため、(ダメだった部分は、最後につけさせていただいております。)uvc_cameraを直接rosmakeも
一応行いました。

camera_umdをROS_PACKAGE_PATHに設定して、
uvc_cameraをrosmakeを行ったところ
下のようにうまく行きました。

そのままサンプルも実行したところ、
カメラ画像が表示されました!
昨日から長い間、ありがとうございました!

なぜかros/fuerteでgit cloneができないのかが未だ気になりますが、
とりあえず、動いてよかったです。


mechuser@UoT-IST-Ub:~/ros/fuerte$ rosmake uvc_camera 
[ rosmake ] rosmake starting...                                           
[ rosmake ] Packages requested are: ['uvc_camera']                        
[ rosmake ] Logging to directory /home/mechuser/.ros/rosmake/rosmake_output-20121120-204907
[ rosmake ] Expanded args ['uvc_camera'] to:
['uvc_camera']               
[rosmake-0] Starting >>> geometry_msgs [ make ]                           
[rosmake-0] Finished <<< geometry_msgs  No Makefile in package geometry_msgs
[rosmake-0] Starting >>> sensor_msgs [ make ]                             
[rosmake-0] Finished <<< sensor_msgs  No Makefile in package sensor_msgs  
[rosmake-0] Starting >>> roslang [ make ]                                 
[rosmake-0] Finished <<< roslang  No Makefile in package roslang          
[rosmake-0] Starting >>> roscpp [ make ]                                  
[rosmake-0] Finished <<< roscpp  No Makefile in package roscpp            
[rosmake-0] Starting >>> common_rosdeps [ make ]                          
[rosmake-0] Finished <<< common_rosdeps ROS_NOBUILD in package common_rosdeps
[rosmake-1] Starting >>> roslib [ make ]                                  
[rosmake-0] Starting >>> camera_calibration_parsers [ make ]              
[rosmake-0] Finished <<< camera_calibration_parsers ROS_NOBUILD in package camera_calibration_parsers
[rosmake-1] Finished <<< roslib  No Makefile in package roslib            
[rosmake-1] Starting >>> rostest [ make ]                                 
[rosmake-0] Starting >>> rosbuild [ make ]                                
[rosmake-1] Finished <<< rostest  No Makefile in package rostest          
[rosmake-0] Finished <<< rosbuild  No Makefile in package rosbuild        
[rosmake-1] Starting >>> camera_info_manager [ make ]                     
[rosmake-0] Starting >>> rosconsole [ make ]                              
[rosmake-0] Finished <<< rosconsole  No Makefile in package rosconsole    
[rosmake-0] Starting >>> pluginlib [ make ]                               
[rosmake-1] Finished <<< camera_info_manager ROS_NOBUILD in package camera_info_manager
[rosmake-1] Starting >>> message_filters [ make ]                         
[rosmake-0] Finished <<< pluginlib ROS_NOBUILD in package pluginlib       
[rosmake-0] Starting >>> rospy [ make ]                                   
[rosmake-0] Finished <<< rospy  No Makefile in package rospy              
[rosmake-0] Starting >>> bond [ make ]                                    
[rosmake-1] Finished <<< message_filters  No Makefile in package message_filters
[rosmake-1] Starting >>> image_transport [ make ]                         
[rosmake-0] Finished <<< bond ROS_NOBUILD in package bond                 
[rosmake-0] Starting >>> smclib [ make ]                                  
[rosmake-1] Finished <<< image_transport ROS_NOBUILD in package image_transport
[rosmake-0] Finished <<< smclib ROS_NOBUILD in package smclib             
[rosmake-0] Starting >>> bondcpp [ make ]                                 
[rosmake-0] Finished <<< bondcpp ROS_NOBUILD in package bondcpp           
[rosmake-0] Starting >>> nodelet [ make ]                                 
[rosmake-0] Finished <<< nodelet ROS_NOBUILD in package nodelet           
[rosmake-0] Starting >>> uvc_camera [ make ]                              
[rosmake-0] Finished <<< uvc_camera [PASS] [ 32.17 seconds ]              
[ rosmake ] Results:                                                      
[ rosmake ] Built 20 packages with 0 failures.                            
[ rosmake ] Summary output to directory                                   
[ rosmake ] /home/mechuser/.ros/rosmake/rosmake_output-20121120-204907 








********************************************************************************:::








mechuser@UoT-IST-Ub:~/ros/fuerte$ rosmake -k roseus_tutorials 
[ rosmake ] rosmake starting...                                           
[ rosmake ] Packages requested are: ['roseus_tutorials']                  
[ rosmake ] Logging to directory /home/mechuser/.ros/rosmake/rosmake_output-20121120-203719
[rosmake-0] Finished <<< euslisp [PASS] [ 1.44 seconds ]                  
[rosmake-0] Starting >>> roseus [ make ]                                  
[rosmake-1] Finished <<< ar_pose [PASS] [ 2.00 seconds ]                  
[rosmake-1] Starting >>> nmpt [ make ]                                    
[ rosmake ] Last 40 linesseus: 2.9 sec ] [ ... [ 2 Active 29/68 Complete ]
[ rosmake ]    /home/mechuser/.ros/rosmake/rosmake_output-20121120-203719/nmpt/build_output.log
[rosmake-1] Finished <<< nmpt [FAIL] [ 1.66 seconds ]                     
[rosmake-1] Starting >>> trajectory_msgs [ make ]                         
[rosmake-1] Finished <<< trajectory_msgs  No Makefile in package trajectory_msgs
[rosmake-1] Starting >>> pr2_controllers_msgs [ make ]                    
[rosmake-1] Finished <<< pr2_controllers_msgs ROS_NOBUILD in package pr2_controllers_msgs
[rosmake-1] Starting >>> rosservice [ make ]                              
[rosmake-1] Finished <<< rosservice  No Makefile in package rosservice    
[rosmake-1] Starting >>> dynamic_reconfigure [ make ]                     
[rosmake-1] Finished <<< dynamic_reconfigure ROS_NOBUILD in package dynamic_reconfigure
[rosmake-1] Starting >>> diagnostic_msgs [ make ]                         
[rosmake-1] Finished <<< diagnostic_msgs  No Makefile in package diagnostic_msgs
[rosmake-1] Starting >>> diagnostic_updater [ make ]                      
[rosmake-1] Finished <<< diagnostic_updater ROS_NOBUILD in package diagnostic_updater
[rosmake-1] Starting >>> self_test [ make ]                               
[rosmake-1] Finished <<< self_test ROS_NOBUILD in package self_test       
[rosmake-1] Starting >>> driver_base [ make ]                             
[rosmake-1] Finished <<< driver_base ROS_NOBUILD in package driver_base   
[rosmake-1] Starting >>> saliency_tracking [ make ]                       
[rosmake-1] Finished <<< saliency_tracking  Package saliency_tracking cannot be built for dependent package(s) [u'nmpt'] failed. 
[rosmake-1] Starting >>> cmvision [ make ]                                
[rosmake-1] Finished <<< cmvision [PASS] [ 2.52 seconds ]                 
[rosmake-1] Starting >>> image_geometry [ make ]                          
[rosmake-1] Finished <<< image_geometry ROS_NOBUILD in package image_geometry
[rosmake-1] Starting >>> checkerboard_pose [ make ]                       
[rosmake-1] Finished <<< checkerboard_pose [PASS] [ 12.80 seconds ]       
[rosmake-1] Starting >>> face_detector_mono [ make ]                      
[rosmake-1] Finished <<< face_detector_mono [PASS] [ 2.58 seconds ]       
[rosmake-1] Starting >>> sound_play [ make ]                              
[rosmake-1] Finished <<< sound_play ROS_NOBUILD in package sound_play     
[rosmake-1] Starting >>> aques_talk [ make ]                              
[rosmake-1] Finished <<< aques_talk [PASS] [ 3.47 seconds ]               
[rosmake-1] Starting >>> posedetection_msgs [ make ]                      
[rosmake-1] Finished <<< posedetection_msgs [PASS] [ 5.91 seconds ]       
[rosmake-1] Starting >>> checkerboard_detector [ make ]                   
[rosmake-1] Finished <<< checkerboard_detector [PASS] [ 3.03 seconds ]    
[rosmake-1] Starting >>> common_rosdeps [ make ]                          
[rosmake-1] Finished <<< common_rosdeps ROS_NOBUILD in package common_rosdeps
[rosmake-1] Starting >>> camera_calibration_parsers [ make ]              
[rosmake-1] Finished <<< camera_calibration_parsers ROS_NOBUILD in package camera_calibration_parsers
[rosmake-1] Starting >>> bond [ make ]                                    
[rosmake-1] Finished <<< bond ROS_NOBUILD in package bond                 
[rosmake-1] Starting >>> smclib [ make ]                                  
[rosmake-1] Finished <<< smclib ROS_NOBUILD in package smclib             
[rosmake-1] Starting >>> bondcpp [ make ]                                 
[rosmake-1] Finished <<< bondcpp ROS_NOBUILD in package bondcpp           
[rosmake-1] Starting >>> nodelet [ make ]                                 
[rosmake-1] Finished <<< nodelet ROS_NOBUILD in package nodelet           
[rosmake-1] Starting >>> image_proc [ make ]                              
[rosmake-1] Finished <<< image_proc ROS_NOBUILD in package image_proc     
[rosmake-1] Starting >>> image_view2 [ make ]                             
[ rosmake ] Output from build of package roseus written to:2/68 Complete ]
[ rosmake ]    /home/mechuser/.ros/rosmake/rosmake_output-20121120-203719/roseus/build_output.log
[rosmake-0] Finished <<< roseus [PASS] [ 60.14 seconds ] -- WARNING: 17 compiler warnings
[rosmake-0] Starting >>> libsiftfast [ make ]                             
[ rosmake ] Output from build of package image_view2 written to:Complete ]
[ rosmake ]    /home/mechuser/.ros/rosmake/rosmake_output-20121120-203719/image_view2/build_output.log
[rosmake-1] Finished <<< image_view2 [PASS] [ 38.63 seconds ] -- WARNING: 1 compiler warnings
[rosmake-1] Starting >>> pcl [ make ]                                     
[rosmake-1] Finished <<< pcl  No Makefile in package pcl                  
[rosmake-1] Starting >>> rosbag [ make ]                                  
[rosmake-1] Finished <<< rosbag  No Makefile in package rosbag            
[rosmake-1] Starting >>> nodelet_topic_tools [ make ]                     
[rosmake-1] Finished <<< nodelet_topic_tools ROS_NOBUILD in package nodelet_topic_tools
[rosmake-1] Starting >>> pcl_ros [ make ]                                 
[rosmake-1] Finished <<< pcl_ros ROS_NOBUILD in package pcl_ros           
[rosmake-1] Starting >>> arm_navigation_msgs [ make ]                     
[rosmake-1] Finished <<< arm_navigation_msgs ROS_NOBUILD in package arm_navigation_msgs
[rosmake-1] Starting >>> distance_field [ make ]                          
[rosmake-1] Finished <<< distance_field ROS_NOBUILD in package distance_field
[rosmake-1] Starting >>> household_objects_database_msgs [ make ]         
[rosmake-1] Finished <<< household_objects_database_msgs ROS_NOBUILD in package household_objects_database_msgs
[rosmake-1] Starting >>> tabletop_object_detector [ make ]                
[rosmake-1] Finished <<< tabletop_object_detector ROS_NOBUILD in package tabletop_object_detector
[rosmake-1] Starting >>> roseus_tutorials [ make ]                        
[ rosmake ] All 32 linesibsiftfast: 12.8 se... [ 2 Active 62/68 Complete ]
{-------------------------------------------------------------------------------
  mkdir -p bin
  cd build && cmake -Wdev -DCMAKE_TOOLCHAIN_FILE=`rospack find rosbuild`/rostoolchain.cmake  ..
  -- The C compiler identification is GNU
  -- The CXX compiler identification is GNU
  -- Check for working C compiler: /usr/bin/gcc
  -- Check for working C compiler: /usr/bin/gcc -- works
  -- Detecting C compiler ABI info
  -- Detecting C compiler ABI info - done
  -- Check for working CXX compiler: /usr/bin/c++
  -- Check for working CXX compiler: /usr/bin/c++ -- works
  -- Detecting CXX compiler ABI info
  -- Detecting CXX compiler ABI info - done
  -- Found PythonInterp: /usr/bin/python2.6
  [rosbuild] Building package roseus_tutorials
  Failed to invoke /opt/ros/fuerte/bin/rospack deps-manifests roseus_tutorials
  [rospack] Error: package/stack roseus_tutorials depends on non-existent package uvc_camera
  
  
  CMake Error at /opt/ros/fuerte/share/ros/core/rosbuild/public.cmake:129 (message):
    
  
    Failed to invoke rospack to get compile flags for package
    'roseus_tutorials'.  Look above for errors from rospack itself.  Aborting.
    Please fix the broken dependency!
  
  Call Stack (most recent call first):
    /opt/ros/fuerte/share/ros/core/rosbuild/public.cmake:203 (rosbuild_invoke_rospack)
    CMakeLists.txt:12 (rosbuild_init)
  
  
  -- Configuring incomplete, errors occurred!
-------------------------------------------------------------------------------}
[ rosmake ] Output from build of package roseus_tutorials written to:
[ rosmake ]    /home/mechuser/.ros/rosmake/rosmake_output-20121120-203719/roseus_tutorials/build_output.log
[rosmake-1] Finished <<< roseus_tutorials [FAIL] [ 0.98 seconds ]         
[ rosmake ] Output from build of package libsiftfast written to:Complete ]
[ rosmake ]    /home/mechuser/.ros/rosmake/rosmake_output-20121120-203719/libsiftfast/build_output.log
[rosmake-0] Finished <<< libsiftfast [PASS] [ 49.94 seconds ] -- WARNING: 2 compiler warnings
[rosmake-0] Starting >>> imagesift [ make ]                               
[ rosmake ] Output from build of package imagesift written to:8 Complete ]
[ rosmake ]    /home/mechuser/.ros/rosmake/rosmake_output-20121120-203719/imagesift/build_output.log
[rosmake-0] Finished <<< imagesift [PASS] [ 27.58 seconds ] -- WARNING: 9 compiler warnings
[rosmake-0] Starting >>> jsk_perception [ make ]                          
^[[C[ rosmake ] [ make ] [ jsk_perception: 47.1... [ 1 Active 64/68 Comple^[[A[ rosmake ] [ make ] [ jsk_perception: 61.0... [ 1 Active 64/68 Comple[ rosmake ] Output from build of package jsk_perception written to:plete ]
[ rosmake ]    /home/mechuser/.ros/rosmake/rosmake_output-20121120-203719/jsk_perception/build_output.log
[rosmake-0] Finished <<< jsk_perception [PASS] [ 176.83 seconds ] -- WARNING: 11 compiler warnings
[ rosmake ] Results:                                                      
[ rosmake ] Built 68 packages with 3 failures.                            
[ rosmake ] Summary output to directory                                   
[ rosmake ] /home/mechuser/.ros/rosmake/rosmake_output-20121120-203719    
mechuser@UoT-IST-Ub:~/ros/fuerte$ rosmake -k roseus_tutorials 


2012年11月20日火曜日 20時27分23秒 UTC+9 垣内(JSK):
> このグループに投稿するには、rtm-ros-robo...@googlegroups.com にメールを送信してください。
> このグループから退会するには、rtm-ros-robotics+unsubscribe@googlegroups.com にメールを送信してください。
> 詳細については、http://groups.google.com/group/rtm-ros-robotics?hl=ja
> からこのグループにアクセスしてください。

上月豊隆

unread,
Jun 14, 2013, 9:15:04 AM6/14/13
to rtm-ros-...@googlegroups.com
上月です

だいぶ前のレスですが、似た症状でつまりました。
~/ros/fuerteで
すると、。

Cloning into 'camera_umd'...
error: Couldn't resolve host 'ram.umd.edu' while accessing http://ram.umd.edu/git/ros/camera_umd.git/info/refs
fatal: HTTP request failed

と表示されます。これはどのように対処すればよいでしょうか。
よろしくおねがいします。


2012年11月20日火曜日 3時45分27秒 UTC+9 垣内(JSK):

>> >> >> >>>> > このグループに投稿するには、rtm-ros-robo...@googlegroups.com
>> >> >> >>>> > にメールを送信してください。
>> >> >> >>>> > このグループから退会するには、rtm-ros-robotics+unsubscribe@googlegroups.com


>> >> >> >>>> > にメールを送信してください。
>> >> >> >>>> > 詳細については、http://groups.google.com/group/rtm-ros-robotics?hl=ja
>> >> >> >>>> > からこのグループにアクセスしてください。
>> >> >> >>>
>> >> >> >>> --
>> >> >> >>> このメールは Google グループのグループ「rtm-ros-robotics」の登録者に送られています。
>> >> >> >>>
>> >> >> >>>
>> >> >> >>>
>> >> >> >>>
>> >> >> >>> このディスカッションをウェブ上で閲覧するには、https://groups.google.com/d/msg/rtm-ros-robotics/-/96iaEyXPA24J
>> >> >> >>> にアクセスしてください。

>> >> >> >>> このグループに投稿するには、rtm-ros-robo...@googlegroups.com にメールを送信してください。
>> >> >> >>> このグループから退会するには、rtm-ros-robotics+unsubscribe@googlegroups.com


>> >> >> >>> にメールを送信してください。
>> >> >> >>> 詳細については、http://groups.google.com/group/rtm-ros-robotics?hl=ja
>> >> >> >>> からこのグループにアクセスしてください。
>> >> >> >
>> >> >> > --
>> >> >> > このメールは Google グループのグループ「rtm-ros-robotics」の登録者に送られています。
>> >> >> >
>> >> >> >
>> >> >> >
>> >> >> > このディスカッションをウェブ上で閲覧するには、https://groups.google.com/d/msg/rtm-ros-robotics/-/rj7mfpLznvAJ
>> >> >> > にアクセスしてください。
>> >> >> >

>> >> >> > このグループに投稿するには、rtm-ros-robo...@googlegroups.com にメールを送信してください。
>> >> >> > このグループから退会するには、rtm-ros-robotics+unsubscribe@googlegroups.com


>> >> >> > にメールを送信してください。
>> >> >> > 詳細については、http://groups.google.com/group/rtm-ros-robotics?hl=ja
>> >> >> > からこのグループにアクセスしてください。
>> >> >
>> >> > --
>> >> > このメールは Google グループのグループ「rtm-ros-robotics」の登録者に送られています。
>> >> >
>> >> >
>> >> > このディスカッションをウェブ上で閲覧するには、https://groups.google.com/d/msg/rtm-ros-robotics/-/PLHJC3epc34J
>> >> > にアクセスしてください。
>> >> >

>> >> > このグループに投稿するには、rtm-ros-robo...@googlegroups.com にメールを送信してください。
>> >> > このグループから退会するには、rtm-ros-robotics+unsubscribe@googlegroups.com


>> >> > にメールを送信してください。
>> >> > 詳細については、http://groups.google.com/group/rtm-ros-robotics?hl=ja
>> >> > からこのグループにアクセスしてください。
>> >
>> > --
>> > このメールは Google グループのグループ「rtm-ros-robotics」の登録者に送られています。
>> >
>> > このディスカッションをウェブ上で閲覧するには、https://groups.google.com/d/msg/rtm-ros-robotics/-/LHsPRKE7WzgJ
>> > にアクセスしてください。
>> >

>> > このグループに投稿するには、rtm-ros-robo...@googlegroups.com にメールを送信してください。
>> > このグループから退会するには、rtm-ros-robotics+unsubscribe@googlegroups.com


>> > にメールを送信してください。
>> > 詳細については、http://groups.google.com/group/rtm-ros-robotics?hl=ja
>> > からこのグループにアクセスしてください。
>
> --
> このメールは Google グループのグループ「rtm-ros-robotics」の登録者に送られています。
> このディスカッションをウェブ上で閲覧するには、https://groups.google.com/d/msg/rtm-ros-robotics/-/zDpkevrJc3cJ
> にアクセスしてください。
>

> このグループに投稿するには、rtm-ros-robo...@googlegroups.com にメールを送信してください。
> このグループから退会するには、rtm-ros-robotics+unsubscribe@googlegroups.com にメールを送信してください。
> 詳細については、http://groups.google.com/group/rtm-ros-robotics?hl=ja
> からこのグループにアクセスしてください。

秋葉直樹

unread,
Jun 17, 2013, 12:08:45 AM6/17/13
to rtm-ros-...@googlegroups.com
山形大学の秋葉直樹と申します.

私も同じ状況になっています.

rtm-rosの下記のサイトでROSをインストールしたのですが,
https://code.google.com/p/rtm-ros-robotics/wiki/ROS_English

rosws update
をおこなったところ

ERROR in config: Error processing 'umd-ros-pkg/camera_umd' :
[umd-ros-pkg/camera_umd] Checkout of
http://ram.umd.edu/git/ros/camera_umd.git version master into
/home/akiba/ros/fuerte/umd-ros-pkg/camera_umd failed.

となり,ネットで解決策を探していたところ,この記事を見つけました.

この記事の前の人は
camera_umd
がホームディレクトリにできて,そこから一応解決に向かっているようですが,
同じようにしてもホームディレクトリにも~/ros/fuerteの下にも作られていません.

解決策をご存じの方がいらっしゃいましたら,アドバイスを頂きたいです.
宜しくお願いいたします.

2013年6月14日 22:15 上月豊隆 <tsubak...@gmail.com>:
>> >> >> >> >>>> > このグループに投稿するには、rtm-ros-...@googlegroups.com
>> >> >> >> >>>> > にメールを送信してください。
>> >> >> >> >>>> >
>> >> >> >> >>>> > このグループから退会するには、rtm-ros-roboti...@googlegroups.com
>> >> >> >> >>>> > にメールを送信してください。
>> >> >> >> >>>> >
>> >> >> >> >>>> > 詳細については、http://groups.google.com/group/rtm-ros-robotics?hl=ja
>> >> >> >> >>>> > からこのグループにアクセスしてください。
>> >> >> >> >>>
>> >> >> >> >>> --
>> >> >> >> >>> このメールは Google グループのグループ「rtm-ros-robotics」の登録者に送られています。
>> >> >> >> >>>
>> >> >> >> >>>
>> >> >> >> >>>
>> >> >> >> >>>
>> >> >> >> >>>
>> >> >> >> >>> このディスカッションをウェブ上で閲覧するには、https://groups.google.com/d/msg/rtm-ros-robotics/-/96iaEyXPA24J
>> >> >> >> >>> にアクセスしてください。
>> >> >> >> >>> このグループに投稿するには、rtm-ros-...@googlegroups.com
>> >> >> >> >>> にメールを送信してください。
>> >> >> >> >>> このグループから退会するには、rtm-ros-roboti...@googlegroups.com
>> >> >> >> >>> にメールを送信してください。
>> >> >> >> >>> 詳細については、http://groups.google.com/group/rtm-ros-robotics?hl=ja
>> >> >> >> >>> からこのグループにアクセスしてください。
>> >> >> >> >
>> >> >> >> > --
>> >> >> >> > このメールは Google グループのグループ「rtm-ros-robotics」の登録者に送られています。
>> >> >> >> >
>> >> >> >> >
>> >> >> >> >
>> >> >> >> >
>> >> >> >> > このディスカッションをウェブ上で閲覧するには、https://groups.google.com/d/msg/rtm-ros-robotics/-/rj7mfpLznvAJ
>> >> >> >> > にアクセスしてください。
>> >> >> >> >
>> >> >> >> > このグループに投稿するには、rtm-ros-...@googlegroups.com にメールを送信してください。
>> >> >> >> > このグループから退会するには、rtm-ros-roboti...@googlegroups.com
>> >> >> >> > にメールを送信してください。
>> >> >> >> > 詳細については、http://groups.google.com/group/rtm-ros-robotics?hl=ja
>> >> >> >> > からこのグループにアクセスしてください。
>> >> >> >
>> >> >> > --
>> >> >> > このメールは Google グループのグループ「rtm-ros-robotics」の登録者に送られています。
>> >> >> >
>> >> >> >
>> >> >> >
>> >> >> > このディスカッションをウェブ上で閲覧するには、https://groups.google.com/d/msg/rtm-ros-robotics/-/PLHJC3epc34J
>> >> >> > にアクセスしてください。
>> >> >> >
>> >> >> > このグループに投稿するには、rtm-ros-...@googlegroups.com にメールを送信してください。
>> >> >> > このグループから退会するには、rtm-ros-roboti...@googlegroups.com
>> >> >> > にメールを送信してください。
>> >> >> > 詳細については、http://groups.google.com/group/rtm-ros-robotics?hl=ja
>> >> >> > からこのグループにアクセスしてください。
>> >> >
>> >> > --
>> >> > このメールは Google グループのグループ「rtm-ros-robotics」の登録者に送られています。
>> >> >
>> >> >
>> >> > このディスカッションをウェブ上で閲覧するには、https://groups.google.com/d/msg/rtm-ros-robotics/-/LHsPRKE7WzgJ
>> >> > にアクセスしてください。
>> >> >
>> >> > このグループに投稿するには、rtm-ros-...@googlegroups.com にメールを送信してください。
>> >> > このグループから退会するには、rtm-ros-roboti...@googlegroups.com
>> >> > にメールを送信してください。
>> >> > 詳細については、http://groups.google.com/group/rtm-ros-robotics?hl=ja
>> >> > からこのグループにアクセスしてください。
>> >
>> > --
>> > このメールは Google グループのグループ「rtm-ros-robotics」の登録者に送られています。
>> >
>> > このディスカッションをウェブ上で閲覧するには、https://groups.google.com/d/msg/rtm-ros-robotics/-/zDpkevrJc3cJ
>> > にアクセスしてください。
>> >
>> > このグループに投稿するには、rtm-ros-...@googlegroups.com にメールを送信してください。
>> > このグループから退会するには、rtm-ros-roboti...@googlegroups.com
>> > にメールを送信してください。
>> > 詳細については、http://groups.google.com/group/rtm-ros-robotics?hl=ja
>> > からこのグループにアクセスしてください。
>
> --
> このメールは Google グループのグループ「rtm-ros-robotics」の登録者に送られています。
> このグループから退会し、メールの受信を停止するには、rtm-ros-roboti...@googlegroups.com
> にメールを送信します。
> このグループに投稿するには、rtm-ros-...@googlegroups.com にメールを送信してください。
> http://groups.google.com/group/rtm-ros-robotics からこのグループにアクセスしてください。
> その他のオプションについては、https://groups.google.com/groups/opt_out にアクセスしてください。
>
>



--
/*************************************
山形大学大学院理工学研究科
機械システム工学専攻
秋葉 直樹
*************************************/

Takuya NAKAOKA

unread,
Jun 17, 2013, 4:51:41 AM6/17/13
to rtm-ros-...@googlegroups.com
稲葉研の中岡です。

ここ数日 http://ram.umd.edu/ のサーバがダウンしている状況で、
gitでソースを取ってこられなくなっています。
ソースコードが要らない場合には、かわりにdebパッケージをインストールすることで回避できます。

roscd
rosws remove umd-ros-pkg/camera_umd
として、umd-ros-pkgを削除したあと、
sudo apt-get install ros-fuerte-camera-umd
とすると、debパッケージ版が入ります。
これでソースからインストールしたときと同じように使えると思います。


2013年6月17日 13:08 秋葉直樹 <nao.luna...@gmail.com>:
中岡 卓也
東京大学大学院 情報理工学系研究科 知能機械情報学専攻
稲葉・岡田研究室(情報システム工学研究室)
〒113-8656 東京都文京区本郷7-3-1 工学部2号館73B1
Tel: 03-5841-7416 / Fax: 03-5841-6285
E-mail: tnak...@jsk.t.u-tokyo.ac.jp

Toyotaka Kozuki

unread,
Jun 17, 2013, 6:55:41 AM6/17/13
to rtm-ros-...@googlegroups.com
中岡君

ありがとうございます、おかげさまで解決しました。

2013年6月17日 17:51 Takuya NAKAOKA <tnak...@jsk.t.u-tokyo.ac.jp>:
*********************************************
Toyotaka Kozuki
Doctor Course student at The University of Tokyo
Mechano-Informatics, Graduate School of Information Science and Technology
Inaba Laboratory(JSK)
7-3-1 Hongo, Bunkyo-ku, Tokyo 113-8656 Japan
Tel: 03-5841-7416 / Fax: 03-5841-6285
Mobile: 090-3693-0971
E-mail: koz...@jsk.t.u-tokyo.ac.jp
*********************************************

秋葉直樹

unread,
Jun 17, 2013, 10:25:29 AM6/17/13
to rtm-ros-...@googlegroups.com
中岡様

山形大学の秋葉です.

指示の通り行ったところ,camera_umdを得ることができました.

また,
rosws update
をおこなったところ
先ほどのエラーが出なくなりました.

アドバイス有難うございました.

2013年6月17日 19:55 Toyotaka Kozuki <koz...@jsk.t.u-tokyo.ac.jp>:
Reply all
Reply to author
Forward
0 new messages