Git Product home page Git Product logo

Comments (4)

tkurki avatar tkurki commented on August 19, 2024

The functionality is minimal, easy to fix. PR?

from signalk-server.

lsoltero avatar lsoltero commented on August 19, 2024

happy to send patches if you want me to do this. basically we redo
DIR="$( cd "$( dirname "${BASH_SOURCE[0]}" )" && pwd )"
and replace it with
DIR=dirname $0
cd $DIR
$DIR/signalk-server -s ./settings/actisense-serial-settings.json $*

and then replace
#!/bin/bash for #!/bin/sh

from signalk-server.

tkurki avatar tkurki commented on August 19, 2024

Sure, nothing beats the smell of easily merged Pull Requests in the morning. Or any time of the day for that matter...

from signalk-server.

lsoltero avatar lsoltero commented on August 19, 2024

the following patch uses readlink to make shell independent startup scripts.

diff --git a/bin/actisense-serial-n2kd b/bin/actisense-serial-n2kd
index e35e159..a5b0d9d 100755
--- a/bin/actisense-serial-n2kd
+++ b/bin/actisense-serial-n2kd
@@ -1,2 +1,3 @@
-#!/bin/bash
-actisense-serial /dev/tty.usbserial-1FD34 | analyzer -json | tee >(n2kd)
\ No newline at end of file
+#!/bin/sh
+actisense-serial /dev/tty.usbserial-1FD34 | analyzer -json | tee >(n2kd)
+
diff --git a/bin/n2k-from-actisense b/bin/n2k-from-actisense
index e63d5fe..defa6a0 100755
--- a/bin/n2k-from-actisense
+++ b/bin/n2k-from-actisense
@@ -1,4 +1,7 @@
-#!/bin/bash
+#!/bin/sh
+
+SP=readlink -f $0
+DIR=dirname $SP
+cd $DIR/..
+$DIR/signalk-server -s ./settings/actisense-serial-settings.json $*

-DIR="$( cd "$( dirname "${BASH_SOURCE[0]}" )" && pwd )"
-$DIR/signalk-server -s ./settings/actisense-serial-settings.json $*
\ No newline at end of file
diff --git a/bin/n2k-from-file b/bin/n2k-from-file
index aa1e290..622d6ef 100755
--- a/bin/n2k-from-file
+++ b/bin/n2k-from-file
@@ -1,4 +1,7 @@
-#!/bin/bash
+#!/bin/sh
+
+SP=readlink -f $0
+DIR=dirname $SP
+cd $DIR/..
+$DIR/signalk-server -s ./settings/aava-file-settings.json $*

-DIR="$( cd "$( dirname "${BASH_SOURCE[0]}" )" && pwd )"
-$DIR/signalk-server -s ./settings/aava-file-settings.json $*
\ No newline at end of file
diff --git a/bin/nmea-from-file b/bin/nmea-from-file
index 34340f2..ab13b6f 100755
--- a/bin/nmea-from-file
+++ b/bin/nmea-from-file
@@ -1,4 +1,7 @@
-#!/bin/bash
+#!/bin/sh
+
+SP=readlink -f $0
+DIR=dirname $SP
+cd $DIR/..
+$DIR/signalk-server -s ./settings/volare-file-settings.json $*

-DIR="$( cd "$( dirname "${BASH_SOURCE[0]}" )" && pwd )"
-$DIR/signalk-server -s ./settings/volare-file-settings.json $*
\ No newline at end of file

from signalk-server.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.