Skip to content

Commit

Permalink
updating pingblog to run budget software
Browse files Browse the repository at this point in the history
  • Loading branch information
MikesGlitch committed Sep 16, 2023
1 parent 453ef5a commit 1ee3ea0
Showing 1 changed file with 25 additions and 0 deletions.
25 changes: 25 additions & 0 deletions utils/PingBlog/Program.cs
@@ -1,4 +1,5 @@
using System;
using System.Diagnostics;
using System.Net.Http;

namespace PingBlog
Expand All @@ -7,6 +8,30 @@ class Program
{
static void Main(string[] args)
{
Console.WriteLine("Running ActualBudget...");

var process = new Process {
StartInfo = new ProcessStartInfo
{
FileName = "cmd.exe",
RedirectStandardInput = true,
RedirectStandardOutput = true,
UseShellExecute = false,
CreateNoWindow = false,
WorkingDirectory = @"D:\GitWork\actual-server",
}
};

try
{
process.Start();
process.StandardInput.WriteLine(@"npm start");
}
catch (Exception ex)
{
Console.WriteLine("ActualBudget Failed", ex.ToString());
}

Console.WriteLine("Starting ping blog service. This service just keeps the blog alive even when nobody is visiting");
var startTimeSpan = TimeSpan.Zero;
var runEveryXMinutes = TimeSpan.FromMinutes(2);
Expand Down

1 comment on commit 1ee3ea0

@vercel
Copy link

@vercel vercel bot commented on 1ee3ea0 Sep 16, 2023

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Please sign in to comment.