Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
adds gitattributes and normalizes line endings
- Loading branch information
Showing
70 changed files
with
3,389 additions
and
3,381 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,8 @@ | ||
* text=auto | ||
|
||
*.jpg binary | ||
*.jpeg binary | ||
*.png binary | ||
*.gif binary | ||
|
||
*.sh text eol=lf |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,17 +1,17 @@ | ||
# Number of days of inactivity before an issue becomes stale | ||
daysUntilStale: 60 | ||
# Number of days of inactivity before a stale issue is closed | ||
daysUntilClose: 7 | ||
# Issues with these labels will never be considered stale | ||
exemptLabels: | ||
- pinned | ||
- security | ||
# Label to use when marking an issue as stale | ||
staleLabel: wontfix | ||
# Comment to post when marking an issue as stale. Set to `false` to disable | ||
markComment: > | ||
This issue has been automatically marked as stale because it has not had | ||
recent activity. It will be closed if no further activity occurs. Thank you | ||
for your contributions. | ||
# Comment to post when closing a stale issue. Set to `false` to disable | ||
# Number of days of inactivity before an issue becomes stale | ||
daysUntilStale: 60 | ||
# Number of days of inactivity before a stale issue is closed | ||
daysUntilClose: 7 | ||
# Issues with these labels will never be considered stale | ||
exemptLabels: | ||
- pinned | ||
- security | ||
# Label to use when marking an issue as stale | ||
staleLabel: wontfix | ||
# Comment to post when marking an issue as stale. Set to `false` to disable | ||
markComment: > | ||
This issue has been automatically marked as stale because it has not had | ||
recent activity. It will be closed if no further activity occurs. Thank you | ||
for your contributions. | ||
# Comment to post when closing a stale issue. Set to `false` to disable | ||
closeComment: false |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,16 +1,16 @@ | ||
bin | ||
obj | ||
packages | ||
.vs | ||
pgp_private_key.txt | ||
pgp_password.txt | ||
*.pem | ||
*.pubxml | ||
*.pubxml.user | ||
*.csproj.user | ||
local.settings.json | ||
appsettings.json | ||
node_modules | ||
lib | ||
.DS_Store | ||
bin | ||
obj | ||
packages | ||
.vs | ||
pgp_private_key.txt | ||
pgp_password.txt | ||
*.pem | ||
*.pubxml | ||
*.pubxml.user | ||
*.csproj.user | ||
local.settings.json | ||
appsettings.json | ||
node_modules | ||
lib | ||
.DS_Store | ||
UserPrefs.xml |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,13 +1,13 @@ | ||
<Project Sdk="Microsoft.NET.Sdk"> | ||
|
||
<PropertyGroup> | ||
<TargetFramework>netstandard2.0</TargetFramework> | ||
</PropertyGroup> | ||
|
||
<ItemGroup> | ||
<PackageReference Include="WindowsAzure.Storage" Version="8.6.0" /> | ||
</ItemGroup> | ||
|
||
<Import Project="../ImgBot.targets" /> | ||
|
||
</Project> | ||
<Project Sdk="Microsoft.NET.Sdk"> | ||
|
||
<PropertyGroup> | ||
<TargetFramework>netstandard2.0</TargetFramework> | ||
</PropertyGroup> | ||
|
||
<ItemGroup> | ||
<PackageReference Include="WindowsAzure.Storage" Version="8.6.0" /> | ||
</ItemGroup> | ||
|
||
<Import Project="../ImgBot.targets" /> | ||
|
||
</Project> |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,23 +1,23 @@ | ||
namespace Common | ||
{ | ||
public static class KnownGitHubs | ||
{ | ||
public const int AppId = 4706; | ||
|
||
public const string AppPrivateKey = "imgbot.2017-08-23.private-key.pem"; | ||
|
||
public const string PGPPrivateKeyFilename = "pgp_private_key.txt"; | ||
|
||
public const string PGPPasswordFilename = "pgp_password.txt"; | ||
|
||
public const string ImgBotLogin = "ImgBotApp"; | ||
|
||
public const string ImgBotEmail = "ImgBotHelp@gmail.com"; | ||
|
||
public const string CommitMessageTitle = "[ImgBot] optimizes images"; | ||
|
||
public const string Username = "x-access-token"; | ||
|
||
public const string BranchName = "imgbot"; | ||
} | ||
} | ||
namespace Common | ||
{ | ||
public static class KnownGitHubs | ||
{ | ||
public const int AppId = 4706; | ||
|
||
public const string AppPrivateKey = "imgbot.2017-08-23.private-key.pem"; | ||
|
||
public const string PGPPrivateKeyFilename = "pgp_private_key.txt"; | ||
|
||
public const string PGPPasswordFilename = "pgp_password.txt"; | ||
|
||
public const string ImgBotLogin = "ImgBotApp"; | ||
|
||
public const string ImgBotEmail = "ImgBotHelp@gmail.com"; | ||
|
||
public const string CommitMessageTitle = "[ImgBot] optimizes images"; | ||
|
||
public const string Username = "x-access-token"; | ||
|
||
public const string BranchName = "imgbot"; | ||
} | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,9 +1,9 @@ | ||
namespace Common | ||
{ | ||
public static class KnownImgPatterns | ||
{ | ||
public static readonly string[] ImgPatterns = { "*.png", "*.jpg", "*.jpeg", "*.gif", }; | ||
|
||
public static readonly string[] ImgExtensions = { ".png", ".jpg", ".jpeg", ".gif", }; | ||
} | ||
} | ||
namespace Common | ||
{ | ||
public static class KnownImgPatterns | ||
{ | ||
public static readonly string[] ImgPatterns = { "*.png", "*.jpg", "*.jpeg", "*.gif", }; | ||
|
||
public static readonly string[] ImgExtensions = { ".png", ".jpg", ".jpeg", ".gif", }; | ||
} | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,11 +1,11 @@ | ||
namespace Common | ||
{ | ||
public static class KnownScheduleSettings | ||
{ | ||
public const string Daily = "daily"; | ||
|
||
public const string Weekly = "weekly"; | ||
|
||
public const string Monthly = "monthly"; | ||
} | ||
} | ||
namespace Common | ||
{ | ||
public static class KnownScheduleSettings | ||
{ | ||
public const string Daily = "daily"; | ||
|
||
public const string Weekly = "weekly"; | ||
|
||
public const string Monthly = "monthly"; | ||
} | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,9 +1,9 @@ | ||
using System.Threading.Tasks; | ||
|
||
namespace Common.Mediation | ||
{ | ||
public interface IMediator | ||
{ | ||
Task SendAsync<T>(T message); | ||
} | ||
} | ||
using System.Threading.Tasks; | ||
|
||
namespace Common.Mediation | ||
{ | ||
public interface IMediator | ||
{ | ||
Task SendAsync<T>(T message); | ||
} | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,24 +1,24 @@ | ||
using System.Threading.Tasks; | ||
using Microsoft.WindowsAzure.Storage.Queue; | ||
using Newtonsoft.Json; | ||
|
||
namespace Common.Mediation | ||
{ | ||
public class QueueMediator : IMediator | ||
{ | ||
private readonly CloudQueueClient _queueClient; | ||
|
||
public QueueMediator(CloudQueueClient queueClient) | ||
{ | ||
_queueClient = queueClient; | ||
} | ||
|
||
public async Task SendAsync<T>(T message) | ||
{ | ||
var queue = _queueClient.GetQueueReference(typeof(T).Name.ToLowerInvariant()); | ||
await queue.CreateIfNotExistsAsync(); | ||
|
||
await queue.AddMessageAsync(new CloudQueueMessage(JsonConvert.SerializeObject(message))); | ||
} | ||
} | ||
} | ||
using System.Threading.Tasks; | ||
using Microsoft.WindowsAzure.Storage.Queue; | ||
using Newtonsoft.Json; | ||
|
||
namespace Common.Mediation | ||
{ | ||
public class QueueMediator : IMediator | ||
{ | ||
private readonly CloudQueueClient _queueClient; | ||
|
||
public QueueMediator(CloudQueueClient queueClient) | ||
{ | ||
_queueClient = queueClient; | ||
} | ||
|
||
public async Task SendAsync<T>(T message) | ||
{ | ||
var queue = _queueClient.GetQueueReference(typeof(T).Name.ToLowerInvariant()); | ||
await queue.CreateIfNotExistsAsync(); | ||
|
||
await queue.AddMessageAsync(new CloudQueueMessage(JsonConvert.SerializeObject(message))); | ||
} | ||
} | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,9 +1,9 @@ | ||
namespace Common | ||
{ | ||
public class RepoConfiguration | ||
{ | ||
public string Schedule { get; set; } | ||
|
||
public string[] IgnoredFiles { get; set; } | ||
} | ||
} | ||
namespace Common | ||
{ | ||
public class RepoConfiguration | ||
{ | ||
public string Schedule { get; set; } | ||
|
||
public string[] IgnoredFiles { get; set; } | ||
} | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,20 +1,20 @@ | ||
using System.Threading.Tasks; | ||
using Microsoft.WindowsAzure.Storage.Table; | ||
|
||
namespace Common.Repository | ||
{ | ||
public interface IRepository | ||
{ | ||
Task InsertOrMergeAsync<T>(T entity) | ||
where T : TableEntity, new(); | ||
|
||
Task<T> RetrieveAsync<T>(string partitionKey, string rowKey) | ||
where T : TableEntity, new(); | ||
|
||
Task DeleteAsync<T>(string partitionKey, string rowKey) | ||
where T : TableEntity, new(); | ||
|
||
Task<T[]> RetrievePartitionAsync<T>(string partitionKey) | ||
where T : TableEntity, new(); | ||
} | ||
using System.Threading.Tasks; | ||
using Microsoft.WindowsAzure.Storage.Table; | ||
|
||
namespace Common.Repository | ||
{ | ||
public interface IRepository | ||
{ | ||
Task InsertOrMergeAsync<T>(T entity) | ||
where T : TableEntity, new(); | ||
|
||
Task<T> RetrieveAsync<T>(string partitionKey, string rowKey) | ||
where T : TableEntity, new(); | ||
|
||
Task DeleteAsync<T>(string partitionKey, string rowKey) | ||
where T : TableEntity, new(); | ||
|
||
Task<T[]> RetrievePartitionAsync<T>(string partitionKey) | ||
where T : TableEntity, new(); | ||
} | ||
} |
Oops, something went wrong.