Skip to content

Commit

Permalink
overwrite option
Browse files Browse the repository at this point in the history
  • Loading branch information
aminya committed Feb 16, 2020
1 parent 0bb697b commit b369509
Showing 1 changed file with 3 additions and 1 deletion.
4 changes: 3 additions & 1 deletion src/bot.jl
Original file line number Diff line number Diff line change
Expand Up @@ -12,6 +12,7 @@ Config object that holds the options and configuration for the SnoopCompile bot.
- `subst::Vector{Pair{UStrings, UStrings}}` : to replace a packages precompile setences with another's package like `["ImageTest" => "Images"]`
- `blacklist::Vector{UStrings}` : to remove some precompile sentences
- `ismultios`::Bool : give true to generate separate precompile files for separate operating systems
- `overwrite::Bool`: to overwrite `precompile_includer.jl` pass `true`
`const UStrings == Union{AbstractString,Regex,AbstractChar}` # every string like type that `replace()` has a method for.
"""
Expand All @@ -20,9 +21,10 @@ struct BotConfig
subst::Vector{Pair{T1, T2}} where {T1<:UStrings, T2 <: UStrings}
blacklist::Vector{T3} where {T3<:UStrings}
ismultios::Bool
overwrite::Bool
end

function BotConfig(packageName::String; subst::Vector{Pair{T1, T2}} where {T1<:UStrings, T2 <: UStrings} = Vector{Pair{String, String}}(), blacklist::Vector{T3} where {T3<:UStrings}= String[], ismultios::Bool=false)
function BotConfig(packageName::String; subst::Vector{Pair{T1, T2}} where {T1<:UStrings, T2 <: UStrings} = Vector{Pair{String, String}}(), blacklist::Vector{T3} where {T3<:UStrings}= String[], ismultios::Bool=false, overwrite::Bool = false)
return BotConfig(packageName, subst, blacklist, ismultios)
end

Expand Down

0 comments on commit b369509

Please sign in to comment.