Visit Our UNIX and Linux User Community

Search Results

Search: Posts Made By: briandanielz
8,027
Posted By briandanielz
Yes it displays the added text. ----------...
Yes it displays the added text.

---------- Post updated at 07:29 PM ---------- Previous update was at 07:05 PM ----------



I tried using this with negative results, I believe it is using an...
8,027
Posted By briandanielz
Yes. Yes and I added the below to my...
Yes.



Yes and I added the below to my .bash_profile

if [[ -f /etc/issue ]]; then
cat /etc/issue;
fi


I get my usual MOTD and
Ubuntu 14.04.2 LTS \n \l
8,027
Posted By briandanielz
admini@myubuntuBox:~$ /sbin/ifconfig eth0 | grep...
admini@myubuntuBox:~$ /sbin/ifconfig eth0 | grep 'inet addr:' | cut -d: -f2 | awk '{ print $1}'
192.168.1.149
admini@myubuntuBox:~$


or

admini@myubuntuBox:~$ /sbin/ifconfig | grep "inet...
8,027
Posted By briandanielz
Display IP adresss at login screen (Ubuntu 14.04)
Hi I tried to follow

ifconfig - How can I display eth0's IP address at the login screen on Precise Server? - Ask Ubuntu...
12,564
Posted By briandanielz
Not in front of a prompt to test. But is that ";"...
Not in front of a prompt to test. But is that ";" needed in
set output 'plot.eps';
705
Posted By briandanielz
Look at the man page. Specifically the "key"...
Look at the man page. Specifically the "key" option. If you do a little searching you can see this question has been answered before.
Forum: Programming 07-28-2014
1,468
Posted By briandanielz
Visual Basic converting a decimal data type to a label with currency format
Here is the code that I am working with. I have tried several other things. any suggestions?

Lbl_Cost_Output.Text = (dDistance * dCostPerMile).ToString("C")

The label is formatted correctly in...
2,159
Posted By briandanielz
Please delete.
After some thought.

I am uncomfortable issuing my professors name where, there may be unintended side effects from any negative responses/feedback. Willing to re post if I can omit school /...
958
Posted By briandanielz
String manipulation.
If a have a variable with a first and last name.
and say the variable looks like this...

FIRST LAST

how could process the variable to look like

First .L

bash 3.2 (osx)
Forum: Programming 09-18-2013
8,188
Posted By briandanielz
"But you're going to run into problems with...
"But you're going to run into problems with garbage stuck in your input because cin hits a newline and refuses to read past it. Are you allowed to use C-style fgets/sscanf ? "

No requirements /...
Forum: Programming 09-17-2013
8,188
Posted By briandanielz
C++ how would you read this file into an array.
here is the pesudo file.

REREREEEEEERRRREER
SOMEStrinG1234 RERRRR EEERRRREER
SOMEStrinG1224 REREREEEREERRR REE
SOMEStrinG1214 REREREREREREREEEER
SOMEStrinG1204 RERE EEEEEERRRRRRR...
Forum: OS X (Apple) 09-08-2013
1,529
Posted By briandanielz
Could you re frame your the problem your trying...
Could you re frame your the problem your trying to solve, by stating exactly what you want the script to do? be more specific?


if the photo has this name do this...
if the folder meets this...
3,628
Posted By briandanielz
with bash string manipulation. ...
with bash string manipulation.


var="/usr/sbin/httpd"
removing_slash="${var##*/}"

echo "$removing_slash"


output

httpd
2,477
Posted By briandanielz
This is really bad, but seems to work. Making...
This is really bad, but seems to work.
Making the assumption that M or F will only appear once on each line
and separated by white space.


while read line
do
if [[ $line == *M* ]];...
1,806
Posted By briandanielz
I would most likely read the file into a variable...
I would most likely read the file into a variable file stored in a trap directory. So upon completion or error the data, would be gobbled up.
37,321
Posted By briandanielz
I think this is interesting, and would be willing...
I think this is interesting, and would be willing to participate if it was about shell scripting. If you look at reddit.com/r/dailyprogrammer and take their model but limit it to bash / linux I...
1,806
Posted By briandanielz
Yes. My bad for not being specific. I was just...
Yes. My bad for not being specific. I was just posting how to extract the variable.

I was thinking loop over the file with an array..
pseudo (untested)

while read line
do
name=$line...
Forum: OS X (Apple) 09-01-2013
3,067
Posted By briandanielz
It looks like the apples man page for ifpw...
It looks like the apples man page for ifpw (https://developer.apple.com/library/mac/documentation/Darwin/Reference/ManPages/man8/ipfw.8.html) answers your question.



Typically when apple does...
1,591
Posted By briandanielz
please delete - wrong solution.
please delete - wrong solution.
1,031
Posted By briandanielz
Thank you. I can see my self using this quite a...
Thank you. I can see my self using this quite a bit.
1,806
Posted By briandanielz
Just using string manipulation... ...
Just using string manipulation...

var='</td><td><a href="geavg.t00z.pgrb2af18">geavg.t00z.pgrb2af18</a>'
var1="${var##*href\=\"}"
var2="${var1%\"\>*}"
echo "$var2"

output ...
3,153
Posted By briandanielz
Bash 3.2 - Array / Regex - IF 3rd member in array ends in 5 digits then do somthing...
Trying to do some control flow parsing based on the index postion of an array member. Here is the pseudo code I am trying to write in (preferably in pure bash) where possible. I am thinking regex...
1,051
Posted By briandanielz
This solved it. for((i=0;i<${#array};i++))...
This solved it.

for((i=0;i<${#array};i++)) {
if [[ ${array[i]} = *@* ]]
then
echo "${array[i]} contains @"
fi
}

Thanks Chubler_XL
1,051
Posted By briandanielz
@Spacebar Not working still. Thanks for you...
@Spacebar
Not working still. Thanks for you input.

Taking this data

First Last
123 some road
some unit
citySTATEZIP
(111) 222-1111
(111) 222-1112
Fax:(111) 222-1113
user@domain.com...
1,051
Posted By briandanielz
Sorry, I am not good with bash functions that do...
Sorry, I am not good with bash functions that do not return void. How would I re-write those so they were inline?
Showing results 1 to 25 of 43

 

Featured Tech Videos

All times are GMT -4. The time now is 11:43 AM.
Unix & Linux Forums Content Copyright 1993-2020. All Rights Reserved.
Privacy Policy