Fix interactive Citation (#91)

This commit is contained in:
Chris de Graaf 2019-08-25 12:00:43 +07:00 committed by GitHub
parent 1a4d1043ee
commit bf828dbaf7
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -26,7 +26,12 @@ struct Citation <: GenericPlugin
end end
end end
interactive(::Type{Citation}) = interactive(Citation; readme_section=false) function interactive(::Type{Citation})
print("Citation: Add a section to README.md mentioning CITATION.bib? [no]: ")
readme = uppercase(readline()) in ["Y", "YES", "TRUE"]
return Citation(; readme_section=readme)
end
function gen_plugin(p::Citation, t::Template, pkg_name::AbstractString) function gen_plugin(p::Citation, t::Template, pkg_name::AbstractString)
pkg_dir = joinpath(t.dir, pkg_name) pkg_dir = joinpath(t.dir, pkg_name)