Giter VIP home page Giter VIP logo

Comments (18)

rehiy avatar rehiy commented on June 24, 2024 3

OK 我发现你是**人,把你的脚本贴出来,我们看看96行是什么代码吧。

from dnspod-shell.

ProfFan avatar ProfFan commented on June 24, 2024

Please check whether you have curl or wget installed.

from dnspod-shell.

rehiy avatar rehiy commented on June 24, 2024

may be have not the dirname commond, you can input the full path instead of it

from dnspod-shell.

DDior avatar DDior commented on June 24, 2024

@ProfFan thx for your response. i checked and confirm that wget and curl have been installed correctly. :)

from dnspod-shell.

DDior avatar DDior commented on June 24, 2024

@anrip i try to run dirname command from ssh, and get below prompts:

SUSWRT-Merlin R7000_3.0.0.4 Sun Jan 31 12:52:51 UTC 2016
admin@R7000-F2A7:/tmp/home/root# dirname
BusyBox v1.20.2 (2015-12-30 09:41:58 CST) multi-call binary.

Usage: dirname FILENAME

Strip non-directory suffix from FILENAME

from dnspod-shell.

ProfFan avatar ProfFan commented on June 24, 2024

You can try "bash -x " and paste the results here.

from dnspod-shell.

DDior avatar DDior commented on June 24, 2024

@ProfFan i run the script on a Router but not Mac...

SUSWRT-Merlin R7000_3.0.0.4 Sun Jan 31 12:52:51 UTC 2016
admin@R7000-F2A7:/tmp/home/root# bash -x
-sh: bash: not found

from dnspod-shell.

ProfFan avatar ProfFan commented on June 24, 2024

then sh -x if you do not have bash

from dnspod-shell.

DDior avatar DDior commented on June 24, 2024

@anrip 若海好。

96行的代码如下:
DIR=$(dirname -- "$(rreadlink "$0")")

from dnspod-shell.

rehiy avatar rehiy commented on June 24, 2024

from dnspod-shell.

ProfFan avatar ProfFan commented on June 24, 2024

现在最重要的是要知道你是什么 shell,因为这个 script 我自己在 zsh、bash 和 sh 上都测试过。

from dnspod-shell.

rehiy avatar rehiy commented on June 24, 2024

from dnspod-shell.

DDior avatar DDior commented on June 24, 2024

@ProfFan merlin 固件用的是busybox,不知道应该算是什么 shell,我运行 sh -x 没有任何回显。
@anrip 不好意思,我的脚本是放在 /jffs/scripts/, 请问如何替换语句?

from dnspod-shell.

DDior avatar DDior commented on June 24, 2024

@ProfFan 方便给个其他联系方式么?我把sh -x的信息贴出来,里面有IP和token之类的信息,不方便贴在这里。

from dnspod-shell.

rehiy avatar rehiy commented on June 24, 2024

from dnspod-shell.

DDior avatar DDior commented on June 24, 2024

@anrip
不好意思,不大懂 shell 编程,请问该替换哪句?是直接替换96行还是前面的某个变量值?

from dnspod-shell.

rehiy avatar rehiy commented on June 24, 2024

DIR=/jffs/scripts/ 即可

from dnspod-shell.

ProfFan avatar ProfFan commented on June 24, 2024

Assumed closed due to inactivity.

from dnspod-shell.

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.