Archived Beta Discussions > SlickEdit 2016 v21 Beta Discussion

RC3 - Using vs during git commit invocation acts funny

(1/1)

astromme:

--- Code: ---[core]
editor = vs +new -snorestore

--- End code ---

When the window comes up, sometimes the cursor is at the top in the first column, sometimes it's in the middle of the second column.

If vs crashes, when I restart it the last commit "file" opens up, so I go delete vrestore.slk; then when I restart it comes up with my old view but no project open.

I'd assume it should NEVER open up with the last commit due to -snorestore - do I have something configured wrong?

Clark:
With the -snorestore option, no files are restored. From what I'm seeing no tool windows/tool bars are restored either. Not sure I like that. I'd prefer a default tool window/tool bar layout be used.

When SlickEdit opens a file, it will restore the cursor location to where it was when the file was closed. If you want the cursor at the top of the file, you need to append "-#top-of-buffer" after the filename.

vs +new -snorestore <filename-here> -#top-of-buffer

It looks like when -snorestore is used, the restore information is still saved on exit. So if the next time you invoke SlickEdit, you don't specify -snorestore, you don't get your old vrestore.slk file.  The work around for this is to specify the -sc option and specify a different configuration location (-sc <tempconfig>)

Clark:
If you want the default tool window/tool bar layout, use the -#reset-window-layout option. I'd put this option before the filename.

vs +new -snorestore -sc <tempconfig> -#reset-window-layout <filename> -#top-of-buffer

FYI: -#<command> executes the command. Very handy.

astromme:
In this case, I very much prefer having no toolbars - I'm presented with a dirt simple window for entering a commit message which is exactly what I want.  If you tweak a default to include toolbars, please continue to provide a "commit instance".

The #top-of-buffer solution is a bit of a pain - instead of

--- Code: --- editor = vs +new -snorestore

--- End code ---
I need

--- Code: --- editor = vs_git

--- End code ---
along with a new vs_git file that looks like

--- Code: ---#/bin/bash
vs +new -snorestore "$1" -#top-of-buffer

--- End code ---
This works, but now I need the extra script anytime I set up a new virtual machine.

What I really want is a braindead window to open to enter a commit message, save it, close the editor, and pretend all that never happened.  So far,

--- Code: --- editor = vs +new -snorestore -snoconfig

--- End code ---
appears to achieve that.. I'll run with this a while.

astromme:
FYI, my idea didn't work (as I'm sure you must've known).  I had to go back to the extra script which looks like


--- Code: ---#!/bin/bash
vs +new -snorestore -snoconfig "$1" -#top-of-buffer

--- End code ---

Navigation

[0] Message Index

Go to full version