Skip to content

Linux. Not printing to file

i’m just coding module for HLDS server extension metamod. I wrote a simple utility function for writing logs in format %LOGNAME%_%DATE%.log In windows that function is working fine, but in linux it create file but write nothing. First I try to search information about that, but I do not found a solution…

Renaming txt files with numbers as filenames in cmd

i have files and This names the files example : I want Rename all of them to file names with numbers like: system windows or linux Answer Just save this code into a name.bat file in your folder and run the command Here in order to avoid conflicts first the files are named as ‘.new’ extenstion and …

How to format decimal space using awk in linux

original file : now i need to control third columns with 6 decimal space after i tried awk {‘print $1,$2; printf “%.6ft”,$3’} but the output is not what I want result : that’s weird , how can I do that will just modify third columns Answer Your print() is adding a newline charact…

Correct version of Ant not being picked by Linux

I get this really annoying message when working with ant on Linux. I export my ANT_HOME=/home/ganesh/org.apache.ant_1.9.2.v201404171502/bin Then i modify my path such as export PATH=$ANT_HOME:$PATH. But then when i run ant i get the error as Error: Could not find or load main class org.apache.tools.ant.launch…