V2EX = way to explore
V2EX 是一个关于分享和探索的地方
Sign Up Now
For Existing Member  Sign In
HXHL
V2EX  ›  macOS

mac 有哪些软件可以远程编辑在服务器上的文件

  •  
  •   HXHL · Oct 10, 2019 · 4609 views
    This topic created in 2394 days ago, the information mentioned may be changed or developed.

    最近在学 php,然后在 centos 上搭了 php 的环境,但是我想用主力机开发( macbook ),有没有什么软件( ide )可以编辑在服务器上的 php 文件,然后保存就可以之前刷新浏览器看效果

    11 replies    2019-10-10 16:43:59 +08:00
    zinplus
        1
    zinplus  
       Oct 10, 2019
    JB 家全系都可以,Tools->Deployment
    Danswerme
        2
    Danswerme  
       Oct 10, 2019 via Android
    vscode 配合 remote ssh 插件
    ericguo
        3
    ericguo  
       Oct 10, 2019
    在 Macbook 上搭建一个本地 php 环境并不麻烦,brew install php,然后 php -S localhost:3000,就可以开发了,不知道为啥喜欢远程开发。。
    zachlhb
        4
    zachlhb  
       Oct 10, 2019 via Android
    @ericguo 方便,现在都是前后端分离,直接远程开发可以方便前端对接,而且集成有些服务必须对外暴露,比如微信公众号,小程序,支付等,而且如果项目中用到国外服务,服务器上可以直连,而本地翻墙很麻烦
    luman
        5
    luman  
       Oct 10, 2019
    php 用 vi 不就够了。。
    U2Fsd
        6
    U2Fsd  
       Oct 10, 2019
    VS Code 上有 Remote Development 但如果 VPS 速度比较慢体验就很差。

    可以使用 SFTP
    保存文件的时候上传到服务器对应路径

    https://marketplace.visualstudio.com/items?itemName=liximomo.sftp
    TimePPT
        7
    TimePPT  
    PRO
       Oct 10, 2019
    ssh 到服务器 VIM 一把梭?

    不过养成良好习惯本地开发调试远程部署比较好,否则线上改崩了很烦人。
    lly0514
        8
    lly0514  
       Oct 10, 2019
    sshfs 跟编辑本地文件没区别
    ruike007
        9
    ruike007  
       Oct 10, 2019
    git 他不香吗
    MrUser
        10
    MrUser  
       Oct 10, 2019
    git +1
    简易版:
    测试好后 push 到 github 之类的上边
    服务器定时从 github 之类的上边 pull,比如 10s pull 一次

    直接改生产环境不好吧?
    About   ·   Help   ·   Advertise   ·   Blog   ·   API   ·   FAQ   ·   Solana   ·   867 Online   Highest 6679   ·     Select Language
    创意工作者们的社区
    World is powered by solitude
    VERSION: 3.9.8.5 · 50ms · UTC 22:20 · PVG 06:20 · LAX 15:20 · JFK 18:20
    ♥ Do have faith in what you're doing.