diff --git a/docs/schema.json b/docs/schema.json index ac7656e..5ad2261 100644 --- a/docs/schema.json +++ b/docs/schema.json @@ -22,7 +22,8 @@ "rem", "slashstarstar", "xml", - "singlequote" + "singlequote", + "percent" ] }, "includes": { @@ -68,4 +69,4 @@ "style", "includes" ] -} \ No newline at end of file +} diff --git a/internal/pkg/core/comment_style.go b/internal/pkg/core/comment_style.go index c5ee2b3..5609a50 100644 --- a/internal/pkg/core/comment_style.go +++ b/internal/pkg/core/comment_style.go @@ -56,6 +56,7 @@ func SupportedStyles() []CommentStyle { styles.SlashStarStar{}, styles.Xml{}, styles.SingleQuote{}, + styles.Percent{}, } } diff --git a/internal/pkg/core/comment_styles/percent.go b/internal/pkg/core/comment_styles/percent.go new file mode 100644 index 0000000..e833acd --- /dev/null +++ b/internal/pkg/core/comment_styles/percent.go @@ -0,0 +1,33 @@ +/* + * Copyright 2019 Florent Biville (@fbiville) + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * https://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +package styles + +type Percent struct { +} + +func (Percent) GetName() string { + return "Percent" +} +func (Percent) GetOpeningString() string { + return "" +} +func (Percent) GetString() string { + return "% " +} +func (Percent) GetClosingString() string { + return "" +}