Skip to main content
added 3 characters in body; edited tags
Source Link
Jeff Schaller
  • 67.7k
  • 35
  • 118
  • 255

I want to store the output from an netcat function into a variable i. I tried a lot of different ways, but it doesn't work to me. Can someone help me? The whole scripting thing is whole new for me!

#! /bin/sh

while true;do
        var = "$(echo "RDTEMP1" | netcat -q2 sanderpi 5033)"
        echo &(var)
        echo "$(date +%Y-%m-%d%t%H:%M:%S)"
done

I want to store the output from an netcat function into a variable i tried a lot of different ways but it doesn't work to me. Can someone help me? The whole scripting thing is whole new for me!

#! /bin/sh

while true;do
        var = "$(echo "RDTEMP1" | netcat -q2 sanderpi 5033)"
        echo &(var)
        echo "$(date +%Y-%m-%d%t%H:%M:%S)"
done

I want to store the output from an netcat function into a variable. I tried a lot of different ways, but it doesn't work to me. Can someone help me? The whole scripting thing is whole new for me!

#! /bin/sh

while true;do
        var = "$(echo "RDTEMP1" | netcat -q2 sanderpi 5033)"
        echo &(var)
        echo "$(date +%Y-%m-%d%t%H:%M:%S)"
done
deleted 21 characters in body
Source Link
Jeff Schaller
  • 67.7k
  • 35
  • 118
  • 255

I want to store the output from an netcat function into a variable i tried a lot of different ways but it doesn't work to me can. Can someone help me? The whole scripting thing is whole new for me :p .!

#! /bin/sh

while true;do
        var = "$(echo "RDTEMP1" | netcat -q2 sanderpi 5033)"
        echo &(var)
        echo "$(date +%Y-%m-%d%t%H:%M:%S)"
done

Thanks a lot !

I want to store the output from an netcat function into a variable i tried a lot of different ways but it doesn't work to me can someone help me? The whole scripting thing is whole new for me :p .

#! /bin/sh

while true;do
        var = "$(echo "RDTEMP1" | netcat -q2 sanderpi 5033)"
        echo &(var)
        echo "$(date +%Y-%m-%d%t%H:%M:%S)"
done

Thanks a lot !

I want to store the output from an netcat function into a variable i tried a lot of different ways but it doesn't work to me. Can someone help me? The whole scripting thing is whole new for me!

#! /bin/sh

while true;do
        var = "$(echo "RDTEMP1" | netcat -q2 sanderpi 5033)"
        echo &(var)
        echo "$(date +%Y-%m-%d%t%H:%M:%S)"
done
Source Link
sanderfcb95
  • 105
  • 2
  • 3
  • 7

Store netcat output into variable

I want to store the output from an netcat function into a variable i tried a lot of different ways but it doesn't work to me can someone help me? The whole scripting thing is whole new for me :p .

#! /bin/sh

while true;do
        var = "$(echo "RDTEMP1" | netcat -q2 sanderpi 5033)"
        echo &(var)
        echo "$(date +%Y-%m-%d%t%H:%M:%S)"
done

Thanks a lot !