-1

I own a laptop and a desktop. The desktop better for training neural networks, but I don't have physical access to it. The laptop is better for day-to-day work on the neural networks. Right now, my workflow is:

  1. Make an edit on my laptop (for example, changing the value of one parameter)
  2. Commit changes
  3. Push to github
  4. SSH into desktop (this just has to be done once)
  5. Pull from github to desktop
  6. Run edited program on desktop

I want to find a workflow that involves fewer steps. What I want is to do all of my work on my laptop, and then be able to immediately run the updated program on my desktop and view the output view ssh.

And ideally I want to do it in a way that does not involve github. If I make some very minor change to a script on my laptop, and I want to run it to see the effect, it makes little sense to commit that change. But I have to commit in order to push. In actuality, what I end up doing is making those small changes on my desktop by editing in vim over ssh. But I want to avoid this, because I don't really like using command-line editors, and because if I'm editing two different local repos, there's a chance of accidentally creating merge conflicts.

Another hope/requirement is that editing be possible when offline. In other words, I'd like to be able to edit locally offline, and then have the files sync whenever I get connectivity.

================================================================

I liked ThatCoolCoder's suggestion of using VSCode. I currently use atom, but it looked like atom has a few packages for this. Any suggestions on which one to try?

=================================================================

Ari Herman
  • 107
  • 1
  • Have you looked into GitHub actions? They could potentially trigger a shell scrip that logs onto your desktop and gets things running. – Adam B Dec 11 '22 at 05:26
  • 3
    Visual studio code has the ability to edit files remotely over SSH. You could edit remotely using VSCode and have a terminal SSH session open in which you actually run the stuff. I've used remote editing in the past and it's worked really well – ThatCoolCoder Dec 11 '22 at 06:46
  • Is your workflow description accurate? I am asking since you did not mention your debugging process. There are developers which don't use or don't need one for their specific work, but I think most of us do. If you don't require a debugger: pulling from github and running the program should be done in one step by a trivial shell script. – Doc Brown Dec 11 '22 at 07:29
  • Or pulling directly from your laptop to the desktop if they are on the same network (or push from your laptop to the desktop). Remember that git is a distributed version control system. GitHub is not even necessary – Greg Burghardt Dec 11 '22 at 14:47
  • 1
    This question is difficult to provide a single answer the community can agree on, because you are asking for general feedback. There are as many valid solutions as there are people. Can you [edit] your question to focus on the problem your current workflow has? "Cumbersome" is not really sufficient to provide an answer. – Greg Burghardt Dec 11 '22 at 14:51
  • @GregBurghardt I've made some edits. Let me know whether or not the question is clearer now. Thanks! – Ari Herman Dec 11 '22 at 15:10
  • While I understand using Git as a source of trust for both, it looks like a bit overkill in this case, given that both PC are on the very same LAN and probably you don't even need Inet connectivity to keep both in-synch. Have you considered using your laptop as a source o trust for the workstation and making the workstation *rsync* with a remote folder (your laptop)? Note that you can schedule periodic _rsync_ by _cronn_ which is also a common resource of Unix O.S's. That's a "pulling" approach, you can do the same pushing (say, periodic sftps from laptop to workstation) – Laiv Dec 12 '22 at 10:54

2 Answers2

0

Use rsync? That can take care of pushing your files to the desktop, but only when necessary. You will still need discipline in order to avoid stepping on yourself, but pretty much you always did.

jimc
  • 119
  • 4
-1

Jetbrain's IDEs support remote developpement.

For my master's research, I used Pycharm to automatically mirror code from my laptop to my lab's workstation and everything worked flawlessly, even over a VPN. This should accomplish exactly what you want.

JS Lavertu
  • 99
  • 2
  • As it’s currently written, your answer is unclear. Please [edit] to add additional details that will help others understand how this addresses the question asked. You can find more information on how to write good answers [in the help center](/help/how-to-answer). – Community Dec 31 '22 at 05:59