Find git executable at run time
[git-darcs-import.git] / src / Darcs / Commands / ShowBug.lhs
blob32ee7e3e6c9c8735963d5895be2909f3c8a1db8e
1 % Copyright (C) 2007 Eric Kow
3 % This program is free software; you can redistribute it and/or modify
4 % it under the terms of the GNU General Public License as published by
5 % the Free Software Foundation; either version 2, or (at your option)
6 % any later version.
8 % This program is distributed in the hope that it will be useful,
9 % but WITHOUT ANY WARRANTY; without even the implied warranty of
10 % MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
11 % GNU General Public License for more details.
13 % You should have received a copy of the GNU General Public License
14 % along with this program; see the file COPYING. If not, write to
15 % the Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor,
16 % Boston, MA 02110-1301, USA.
18 \subsection{darcs show bug}
19 \begin{code}
20 {-# OPTIONS_GHC -cpp #-}
21 {-# LANGUAGE CPP #-}
23 module Darcs.Commands.ShowBug ( show_bug ) where
25 import Darcs.Commands ( DarcsCommand(..), nodefaults )
26 import Darcs.Arguments ( DarcsFlag, working_repo_dir )
27 import Darcs.Repository ( findRepository )
28 #include "impossible.h"
29 \end{code}
31 \options{show bug}
32 \begin{code}
33 show_bug_description :: String
34 show_bug_description = "Pretends to be a bug in darcs."
35 \end{code}
36 \haskell{show_bug_help}
37 \begin{code}
38 show_bug_help :: String
39 show_bug_help =
40 "Show bug can be used to see what darcs would show you if you encountered.\n"
41 ++"a bug in darcs.\n"
43 show_bug :: DarcsCommand
44 show_bug = DarcsCommand {command_name = "bug",
45 command_help = show_bug_help,
46 command_description = show_bug_description,
47 command_extra_args = 0,
48 command_extra_arg_help = [],
49 command_command = show_bug_cmd,
50 command_prereq = findRepository,
51 command_get_arg_possibilities = return [],
52 command_argdefaults = nodefaults,
53 command_advanced_options = [],
54 command_basic_options = [working_repo_dir]}
55 \end{code}
57 \begin{code}
58 show_bug_cmd :: [DarcsFlag] -> [String] -> IO ()
59 show_bug_cmd _ _ = bug "This is actually a fake bug in darcs."
60 \end{code}