How can I get a list of programs in my path from Perl?
How can I list all available UNIX commands from Perl? ...
How can I list all available UNIX commands from Perl? ...
I'm currently writing a Java application to be used with a Windows-Machine authed with an ActiveDirectory. The application basically only needs to know the user's name and hostname. I know there are System.getProperty("user.name") and java.net.InetAddress.getLocalHost().getHostName() But I am not sure wether System.getProperty("user....
I know this is silly but I can't overcome my curiosity. Is it possible to write a shell script to format a piece of java code? For example, if a user writes in a code: public class Super{ public static void main(String[] args){ System.out.println("Hello world"); int a=0; if(a==100) { System.out.println("Hel...
I can use stat() to figure out what permissions the owner, group, or others have and I can use geteuid() and getpwuid() to get the user name of the process. I'm not quite sure how to get the groups a user belongs to without a system call though. Even knowing how to get the groups, it seems like a lot of work to integrate all of this ...
I'm curious if there are any SubSonic ports for use with php on a unix environment. I'm using SubSonic at work and I love it, and I'd like to create a MySQL database on a FreeBSD server and talk to it using php. I was hoping to use SubSonic again, but I'm not sure if there are any versions of it that work with php. Are there any versi...
I want to know what is the standard way of doing it. currently I'm thinking in add a series of defines in a header file and inlcudie that file in the main resource file win win32 to update the version resource in win32 and in *nix make some global functions to return this information. and in windows make the msi install file also refle...
Is it considered a soft bounce, like a transmission or SMTP error, and we should try again? Or treat it as a hard bounce? Thanks. ...
Im trying to create a synchronization between [Unfuddle][1] and my local server so that when there is a SVN commit on Unfuddle, my local server's code automatically gets updated. Unfuddle provides a callback and I can get the callback when a commit is made. Now my webserver runs as the user called "apache", but all the files that are ex...
In my .zshrc I've set up suffix completion aliases like this so that I can open files more easily: alias -s -- txt='mate -w' Which allows me to open text files in my text editor without prepending the editor command. There is a problem, however, when I am attempting to open a file with a capitalized suffix. ZSH will recognize '.txt' ...
Is there a difference between compiling projects in *nix enviroments and MS Visual C++? For example, there is a "stdafx.h" file in Visual C++. The reason I'm asking is that I submitted a piece of code which compiled in g++, to refactormycode.com. Then after it got a refactoring, it seemed to include a "stdafx.h", so I figured I'll down...
I have a child process which generates some output of variable length and then sends it to the parent using a half duplex pipe. In the parent, how do I use the read() function? Since the data can be of different length each time, how can I at run time know the size of the data to do any malloc() for a buffer? Can the fstat() function be ...
Borderline ServerFault question, but I'm programming some shell scripts, so I'm trying here first :) Most *nixes have a command that will let you pipe/redirect output to the local clipboard/pasteboard, and retrieve from same. On OS X these commands are pbcopy, pbpaste Is there anyway to replicate this functionality while SSHed into ...
I start a jetty server on linux using nohup mvn jetty:run & to run it in background and to stay when I quit from the console. Usually (mvn jetty:run) it starts in seconds, but in this case it takes about minute to start. What can be the cause of such a delay? Thanks. ...
In general, what can we take for granted when we append to a file in UNIX from multiple processes? Is it possible to lose data (one process overwriting the other's changes)? Is it possible for data to get mangled? (For example, each process is appending one line per append to a log file, is it possible that two lines get mangled?) If...
Hi, I want to use Python to get the group id to a corresponding group name. The routine must work for Unix-like OS (Linux and Mac OS X). Best, ~S Edit: This is what I found so far >>> import grp >>> for g in grp.getgrall(): ... if g[0] == 'wurzel': ... print g[2] ...
I need to use chmod to change all files recursivly to 664. I would like to skip the folders. I was thinking of doing something like this ls -lR | grep ^-r | chmod 664 This doesn't work, I'm assuming because I can't pipe into chmod Anyone know of an easy way to do this? Thanks ...
I am in the process of answering a request for tender on a contract that requires a decent amount of text processing. The main trouble is that the customer wants to be able to run this on any UNIX (HPUX, Solaris, AIX, FreeBSD) or Linux (SLES, RHEL) platform, which may constrain what I use to do it. They don't want to make the installatio...
I want to try out some of the MySQL software, like Workbench, on the MySQL Db I develop on at work. After many failed attempts to make the connection, I finally asked one of the server admins if I was doing something wrong and was informed that the Db is behind firewall. So I can use phpMyAdmin, since it's installed server-side, but not ...
Hey everyone, I'm writing a pretty basic application in python (it's only one file at the moment). My question is how do I get it so the python script is able to be run in /usr/bin without the .py extension? For example, instead of running python htswap.py args from the directory where it currently is, I want to be able to cd to any...
I am looking for a Unix based application or framework that would allow me to view/edit ini files on a remote system in a Html GUI via Apache (or similar). Searching for ini/config/GUI solutions via search engines returns a lot a false positives. Any recommendations? ...