From 4929fb529756d82f59fdb258794f2cf052e91bb6 Mon Sep 17 00:00:00 2001 From: Scott Williams Date: Sat, 19 Aug 2017 11:22:44 +0100 Subject: [PATCH] fix style cop issues --- gitversion.yml | 8 ++++++++ .../Formats/Jpeg/GolangPort/OldJpegDecoder.cs | 12 +++++++----- .../Formats/Jpeg/PdfJsPort/Components/IDCT.cs | 11 +++++++---- .../PdfJsPort/Components/YCbCrToRgbTables.cs | 10 ++++++---- .../ImageSharp.Benchmarks/Color/RgbToYCbCr.cs | 18 ++++++++++-------- .../General/RoundSinglePrecisionBlocks.cs | 14 ++++++++------ 6 files changed, 46 insertions(+), 27 deletions(-) diff --git a/gitversion.yml b/gitversion.yml index e07c90f0d..8a5422bd2 100644 --- a/gitversion.yml +++ b/gitversion.yml @@ -9,5 +9,13 @@ branches: increment: Minor prevent-increment-of-merged-branch-version: false track-merge-target: true + branch: + regex: '.*' + mode: ContinuousDeployment + tag: ci + increment: Patch + prevent-increment-of-merged-branch-version: false + track-merge-target: true + is-release-branch: false ignore: sha: [] \ No newline at end of file diff --git a/src/ImageSharp/Formats/Jpeg/GolangPort/OldJpegDecoder.cs b/src/ImageSharp/Formats/Jpeg/GolangPort/OldJpegDecoder.cs index 602cd7066..60a2e1246 100644 --- a/src/ImageSharp/Formats/Jpeg/GolangPort/OldJpegDecoder.cs +++ b/src/ImageSharp/Formats/Jpeg/GolangPort/OldJpegDecoder.cs @@ -1,9 +1,11 @@ -namespace SixLabors.ImageSharp.Formats.Jpeg.GolangPort -{ - using System.IO; +// Copyright (c) Six Labors and contributors. +// Licensed under the Apache License, Version 2.0. - using SixLabors.ImageSharp.PixelFormats; +using System.IO; +using SixLabors.ImageSharp.PixelFormats; +namespace SixLabors.ImageSharp.Formats.Jpeg.GolangPort +{ /// /// Image decoder for generating an image out of a jpg stream. /// @@ -19,7 +21,7 @@ namespace SixLabors.ImageSharp.Formats.Jpeg.GolangPort where TPixel : struct, IPixel { Guard.NotNull(stream, nameof(stream)); - + using (var decoder = new OldJpegDecoderCore(configuration, this)) { return decoder.Decode(stream); diff --git a/src/ImageSharp/Formats/Jpeg/PdfJsPort/Components/IDCT.cs b/src/ImageSharp/Formats/Jpeg/PdfJsPort/Components/IDCT.cs index 7a1a2114f..276ae8763 100644 --- a/src/ImageSharp/Formats/Jpeg/PdfJsPort/Components/IDCT.cs +++ b/src/ImageSharp/Formats/Jpeg/PdfJsPort/Components/IDCT.cs @@ -1,8 +1,11 @@ -namespace SixLabors.ImageSharp.Formats.Jpeg.PdfJsPort.Components -{ - using System; - using System.Runtime.CompilerServices; +// Copyright (c) Six Labors and contributors. +// Licensed under the Apache License, Version 2.0. + +using System; +using System.Runtime.CompilerServices; +namespace SixLabors.ImageSharp.Formats.Jpeg.PdfJsPort.Components +{ /// /// Performs the inverse Descrete Cosine Transform on each frame component. /// diff --git a/src/ImageSharp/Formats/Jpeg/PdfJsPort/Components/YCbCrToRgbTables.cs b/src/ImageSharp/Formats/Jpeg/PdfJsPort/Components/YCbCrToRgbTables.cs index 9ed15cacb..e4f99275b 100644 --- a/src/ImageSharp/Formats/Jpeg/PdfJsPort/Components/YCbCrToRgbTables.cs +++ b/src/ImageSharp/Formats/Jpeg/PdfJsPort/Components/YCbCrToRgbTables.cs @@ -1,9 +1,11 @@ -namespace SixLabors.ImageSharp.Formats.Jpeg.PdfJsPort.Components -{ - using System.Runtime.CompilerServices; +// Copyright (c) Six Labors and contributors. +// Licensed under the Apache License, Version 2.0. - using SixLabors.ImageSharp.PixelFormats; +using System.Runtime.CompilerServices; +using SixLabors.ImageSharp.PixelFormats; +namespace SixLabors.ImageSharp.Formats.Jpeg.PdfJsPort.Components +{ /// /// Provides 8-bit lookup tables for converting from YCbCr to Rgb colorspace. /// Methods to build the tables are based on libjpeg implementation. diff --git a/tests/ImageSharp.Benchmarks/Color/RgbToYCbCr.cs b/tests/ImageSharp.Benchmarks/Color/RgbToYCbCr.cs index 51be951c1..4048b2569 100644 --- a/tests/ImageSharp.Benchmarks/Color/RgbToYCbCr.cs +++ b/tests/ImageSharp.Benchmarks/Color/RgbToYCbCr.cs @@ -1,14 +1,16 @@ -namespace SixLabors.ImageSharp.Benchmarks -{ - using System; - using System.Buffers; - using System.Numerics; - using System.Runtime.CompilerServices; +// Copyright (c) Six Labors and contributors. +// Licensed under the Apache License, Version 2.0. - using BenchmarkDotNet.Attributes; +using System; +using System.Buffers; +using System.Numerics; +using System.Runtime.CompilerServices; - using SixLabors.ImageSharp.Formats.Jpg; +using BenchmarkDotNet.Attributes; +using SixLabors.ImageSharp.Formats.Jpeg.Common; +namespace SixLabors.ImageSharp.Benchmarks +{ public partial class RgbToYCbCr { private const int InputColorCount = 64; diff --git a/tests/ImageSharp.Benchmarks/General/RoundSinglePrecisionBlocks.cs b/tests/ImageSharp.Benchmarks/General/RoundSinglePrecisionBlocks.cs index a4e5f358c..284e20859 100644 --- a/tests/ImageSharp.Benchmarks/General/RoundSinglePrecisionBlocks.cs +++ b/tests/ImageSharp.Benchmarks/General/RoundSinglePrecisionBlocks.cs @@ -1,12 +1,14 @@ -namespace SixLabors.ImageSharp.Benchmarks.General -{ - using System.Numerics; - using System.Runtime.CompilerServices; +// Copyright (c) Six Labors and contributors. +// Licensed under the Apache License, Version 2.0. - using BenchmarkDotNet.Attributes; +using System.Numerics; +using System.Runtime.CompilerServices; - using SixLabors.ImageSharp.Formats.Jpg; +using BenchmarkDotNet.Attributes; +using SixLabors.ImageSharp.Formats.Jpeg.Common; +namespace SixLabors.ImageSharp.Benchmarks.General +{ /// /// The goal of this benchmark is to measure the following Jpeg-related scenario: /// - Take 2 blocks of float-s