@@ -147,22 +147,34 @@ initToReport exit =
150− = DiffApplication
151+ | DiffApplication
151 | DiffUnpublished
152 | DiffUnpublished
152 | DiffUnknownPackage Pkg.Name [Pkg.Name]
153 | DiffUnknownPackage Pkg.Name [Pkg.Name]
153 | DiffUnknownVersion Pkg.Name V.Version [V.Version]
154 | DiffUnknownVersion Pkg.Name V.Version [V.Version]
154− | DiffCannotFindDocs DocsProblem
155+ | DiffDocsProblem DocsProblem
155− | DiffMustHaveLatestRegistry RegistryProblem
156+ | DiffBadRegistry RegistryProblem
157+ | DiffBadDetails Details
158diffToReport :: Diff -> Help.Report
160diffToReport :: Diff -> Help.Report
159diffToReport diff =
161diffToReport diff =
160 case diff of
162 case diff of
164+ Help.report "DIFF WHAT?" Nothing
165+ "I cannot find an elm.json so I am not sure what you want me to diff.\
166+ \ Normally you run `elm diff` from within a project!"
167+ [ D.reflow $ "If you are just curious to see a diff, try running this command:"
168+ , D.indent 4 $ D.green $ "elm diff elm/html 5.1.1 6.0.0"
161 DiffApplication ->
171 DiffApplication ->
162 Help.report "CANNOT DIFF APPLICATIONS" Nothing
172 Help.report "CANNOT DIFF APPLICATIONS" Nothing
163− "I cannot perform diffs on applications, only packages! If you are\
173+ "It looks like you are running `elm diff` on an application, but it\
174+ \ only makes sense for packages that have been published. That way\
175+ \ there is a fixed API to diff against."
164− \ just curious to see a diff, try running this command:"
176+ [ D.reflow $ "If you are just curious to see a diff, try running this command:"
165− [ D.indent 4 $ D.green $ "elm diff elm/html 5.1.1 6.0.0"
177+ , D.indent 4 $ D.green $ "elm diff elm/html 5.1.1 6.0.0"
168 DiffUnpublished ->
180 DiffUnpublished ->
@@ -198,11 +210,11 @@ diffToReport diff =
198 , "Want one of those instead?"
210 , "Want one of those instead?"
201− DiffCannotFindDocs problem ->
213+ DiffDocsProblem problem ->
202− error "TODO DiffCannotFindDocs" problem
214+ error "TODO DiffDocsProblem" problem
204− DiffMustHaveLatestRegistry problem ->
216+ DiffBadRegistry problem ->
205− error "TODO DiffMustHaveLatestRegistry" problem
217+ error "TODO DiffBadRegistry" problem