Jump to content
Ketarin forum

Ketarin 1.1.4.344


floele
 Share

Recommended Posts

Hi,

 

a new minor release with a couple of additions:

 

+Added variable {startuppath}

+Show file properties (F9)

+Added time and time-x/time+x variables for Unix timestamp (useful for SF.net downloads)

!Fixed: Status column does not sort properly

!Fixed a possible NullReferenceException

 

Regards,

Flo

Link to comment
Share on other sites

Hi, Flo!

 

I still can't get {startuppath} to work within the global commands. Is there a trick to it? Trying to execute:

echo {category} /// {appname} {version} >> "{startuppath}\Updates.txt"

 

The output still uses the literal text "{startuppath}" though. :(

 

This is what the above actually attempts to execute:

 

Plugins /// Java x86 6u21 >> "{startuppath}\Updates.txt"

Link to comment
Share on other sites

You don't have to use {startuppath} to write your log file.

 

Remove your startuppath variable and it will create Updates.txt in the same folder the Ketarin.exe is located.

 

echo %date% - %time% // {category} {appname} v{version} >> Updates.txt

Link to comment
Share on other sites

Okay, how do I open it in N++? Currently, I use:

"C:\Program Files (x86)\Notepad++\notepad++.exe" "%USERPROFILE%\Desktop\Updates.txt"

 

That's not possible, and my attempt to include just the filename fail. Neither of these work to open the file in N++, even though txt files are associated with it:

"%USERPROFILE%\Desktop\Updates.txt"

Updates.txt

Link to comment
Share on other sites

You have to split it into two different steps. The first one is to save the file. And the second one is to open it.

 

echo %date% - %time% // {category} - {appname} - {version} >> "Updates.txt"

start "%ProgramFiles(x86)%\Notepad++\notepad++.exe" "Updates.txt"

 

 

And if the Update.txt is located on desktop just change the path to "%USERPROFILE%\Desktop\Updates.txt"

Link to comment
Share on other sites

"%ProgramFiles(x86)%" doesn't exist on 32-bit computers, so it won't work in my screwy network. I know, I've been through this a lot trying to find a reliable cross-platform method to use the same jobs.db and local (network storage) cache settings without having to change settings based on the environment.

 

The start command should really be avoided too, since it's not cross-platform consistent.

 

Maybe the best method is to set the executeable based on the system variables?

 

IF "%ProgramFiles(x86)%"=="" THEN "%ProgramFiles%\Notepad++\notepad++.exe" "Updates.txt"
IF NOT "%ProgramFiles(x86)%"=="" THEN "%ProgramFiles(x86)%\Notepad++\notepad++.exe" "Updates.txt"

Link to comment
Share on other sites

ProcExp shows that the same environment variables I expect to be there, but that wasn't the problem. It was "THEN". Batch doesn't understand it. Removed, and working fine now:

IF "%ProgramFiles(x86)%"=="" "%ProgramFiles%\Notepad++\notepad++.exe" "Updates.txt"
IF NOT "%ProgramFiles(x86)%"=="" "%ProgramFiles(x86)%\Notepad++\notepad++.exe" "Updates.txt"

 

Thanks everyone!

Link to comment
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
 Share

×
×
  • Create New...

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.