12-15-2016
This is going to be a royal pain to do in the shell. You're going to get stuck waiting on input from the web service while the web browser is stuck waiting on input for you. Named pipes are prone to this, even used one-way -- using a pair means almost guaranteed deadlock.
If you have Python or Perl, I'd look into writing it in that language instead. You would use a socket directly, avoiding the need for these deadlocks.
Another alternative, which I know you didn't want, would be the expect language. It can work pretty much the way you were expecting - run a program, check if it's got input, check if it's got output, decide what do do with it, move on.
10 More Discussions You Might Find Interesting
1. Programming
Hi Folks
I am not a c programmer .But i need help in writing a program which can do this any ideas on how to go about it .
i start a server on the target server where files need to be copied
start-server -port 5006 & ---start the server and listen it on a partcular port
on the source... (2 Replies)
Discussion started by: linuxdba
2 Replies
2. UNIX for Advanced & Expert Users
I'd like to do a data transfer without encryption but with a guarantee that my data comes from a legit source. I'm thinking something that uses a public key scheme to sign the data.
Does anyone know of something like that?
Thanks!
-Pileofrogs (1 Reply)
Discussion started by: pileofrogs
1 Replies
3. Shell Programming and Scripting
Is there a way how to react on the message a client sent to the server?
I would like as the client sent message to server: "get information such and such" and server would answer.
Thank you for reply! (6 Replies)
Discussion started by: MartyIX
6 Replies
4. UNIX for Advanced & Expert Users
Hi all,
When using netcat to transfer the data over socket, if no connection is established, how long will netcat keep the data; will it discard the "oldest" data ?
Say for example I use "Some Command | netcat -l -p port", the command I use will generate a lot of output constantly, while no... (2 Replies)
Discussion started by: qiulang
2 Replies
5. UNIX and Linux Applications
Please direct me to the right forum tree if i am in the wrong section for this.
i have netcat on a unix machine and there is no man nc or man netcat available.
my command i am using is:
cat $FILE1 | netcat -h $PRINTER -p 9100
(-h -p -d are the only flags available in this version of... (3 Replies)
Discussion started by: dunpealslyr
3 Replies
6. Solaris
hello guys, i want to install netcat on my solaris. after i tar and gunzip netcat i'm confuse what do i must to do ? please help me to install netcat on my solaris. I'm beginner :( (2 Replies)
Discussion started by: praset
2 Replies
7. Linux
Hello,
Thank you very much for the line nc -lp <port> . I tried to run simple chat session with nc as it's shown in catonmatDOTorg but failed miserably with that syntax inspite of opening port 7777 by iptables . But your command example is working nicely.
So a bagful of thanks :))
Only one... (0 Replies)
Discussion started by: vectrum
0 Replies
8. Shell Programming and Scripting
Hi;
I have a url like
http://localhost:8080/examples/jsp/dates/nextPageToPost.jsp?name=ajay&password=pas&sex=Male&check=on&nationality=USA&description=aa&submit=submit
in which i want to use nc for http post for parameters like "name","password"....etc
can neone please help me how to do that... (3 Replies)
Discussion started by: ajaypadvi
3 Replies
9. IP Networking
Hi all,
I know my question is regarding Windows and not Linux, but I simply need people who know Netcat pretty well and I'm guessing here is a good place for that. So on with my question.
I'm doing some research, and I was playing around with netcat on a WinXP VM but I can't seem to get... (0 Replies)
Discussion started by: MrCrumbs
0 Replies
10. UNIX for Advanced & Expert Users
Currently I run a number of network tests using netcat that checks for an open port on a remote IP-address, using this syntax:
netcat -v -w 5 -z 107.249.95.5 4488
For some reason, the netcat command above is hanging (although others work fine), but a telnet is showing a valid connection like... (4 Replies)
Discussion started by: ckmehta
4 Replies
LEARN ABOUT XFREE86
git-web--browse
GIT-WEB--BROWSE(1) Git Manual GIT-WEB--BROWSE(1)
NAME
git-web--browse - Git helper script to launch a web browser
SYNOPSIS
git web--browse [OPTIONS] URL/FILE ...
DESCRIPTION
This script tries, as much as possible, to display the URLs and FILEs that are passed as arguments, as HTML pages in new tabs on an already
opened web browser.
The following browsers (or commands) are currently supported:
o firefox (this is the default under X Window when not using KDE)
o iceweasel
o seamonkey
o iceape
o chromium (also supported as chromium-browser)
o google-chrome (also supported as chrome)
o konqueror (this is the default under KDE, see Note about konqueror below)
o opera
o w3m (this is the default outside graphical environments)
o elinks
o links
o lynx
o dillo
o open (this is the default under Mac OS X GUI)
o start (this is the default under MinGW)
o cygstart (this is the default under Cygwin)
o xdg-open
Custom commands may also be specified.
OPTIONS
-b <browser>, --browser=<browser>
Use the specified browser. It must be in the list of supported browsers.
-t <browser>, --tool=<browser>
Same as above.
-c <conf.var>, --config=<conf.var>
CONF.VAR is looked up in the Git config files. If it's set, then its value specifies the browser that should be used.
CONFIGURATION VARIABLES
CONF.VAR (from -c option) and web.browser
The web browser can be specified using a configuration variable passed with the -c (or --config) command-line option, or the web.browser
configuration variable if the former is not used.
browser.<tool>.path
You can explicitly provide a full path to your preferred browser by setting the configuration variable browser.<tool>.path. For example,
you can configure the absolute path to firefox by setting browser.firefox.path. Otherwise, git web--browse assumes the tool is available in
PATH.
browser.<tool>.cmd
When the browser, specified by options or configuration variables, is not among the supported ones, then the corresponding
browser.<tool>.cmd configuration variable will be looked up. If this variable exists then git web--browse will treat the specified tool as
a custom command and will use a shell eval to run the command with the URLs passed as arguments.
NOTE ABOUT KONQUEROR
When konqueror is specified by a command-line option or a configuration variable, we launch kfmclient to try to open the HTML man page on
an already opened konqueror in a new tab if possible.
For consistency, we also try such a trick if browser.konqueror.path is set to something like A_PATH_TO/konqueror. That means we will try to
launch A_PATH_TO/kfmclient instead.
If you really want to use konqueror, then you can use something like the following:
[web]
browser = konq
[browser "konq"]
cmd = A_PATH_TO/konqueror
Note about git-config --global
Note that these configuration variables should probably be set using the --global flag, for example like this:
$ git config --global web.browser firefox
as they are probably more user specific than repository specific. See git-config(1) for more information about this.
GIT
Part of the git(1) suite
Git 2.17.1 10/05/2018 GIT-WEB--BROWSE(1)