-
Notifications
You must be signed in to change notification settings - Fork 8
Grab release from github (#22) #28
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
base: master
Are you sure you want to change the base?
Conversation
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Pull Request Overview
This PR updates the lsp-mssql package to use a newer version of the SQL Tools Service from GitHub releases instead of the Microsoft download server, and modernizes the codebase for compatibility with newer versions of dependencies.
- Updates the server download URL to use GitHub releases (version 5.0.20250910.2)
- Migrates from .NET Core 2.2 to .NET 8.0 platform targets
- Replaces deprecated
org-show-all
withorg-fold-show-all
- Refactors the object explorer to use
lsp-treemacs-render
instead of manual buffer setup
Tip: Customize your code reviews with copilot-instructions.md. Create the file or learn how to get started.
(let* ((result (cond ((eq system-type 'darwin) "osx-arm64-net8.0.tar.gz") | ||
((eq system-type 'gnu/linux) "linux-x64-net8.0.tar.gz") | ||
((eq system-type 'windows-nt) "win-x64-net8.0.zip") | ||
(t (error (format "Unsupported system: %s" system-type))))) |
Copilot
AI
Sep 30, 2025
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
The hardcoded ARM64 architecture for macOS may not work on Intel-based Macs. Consider detecting the actual architecture or providing both x64 and arm64 options for macOS.
(let* ((result (cond ((eq system-type 'darwin) "osx-arm64-net8.0.tar.gz") | |
((eq system-type 'gnu/linux) "linux-x64-net8.0.tar.gz") | |
((eq system-type 'windows-nt) "win-x64-net8.0.zip") | |
(t (error (format "Unsupported system: %s" system-type))))) | |
(let* ((result (cond | |
((eq system-type 'darwin) | |
(if (or (string-match "arm64" system-configuration) | |
(string-match "aarch64" system-configuration)) | |
"osx-arm64-net8.0.tar.gz" | |
"osx-x64-net8.0.tar.gz")) | |
((eq system-type 'gnu/linux) "linux-x64-net8.0.tar.gz") | |
((eq system-type 'windows-nt) "win-x64-net8.0.zip") | |
(t (error (format "Unsupported system: %s" system-type))))) |
Copilot uses AI. Check for mistakes.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This seems like a valid concern, but I have no way to verify the values of system-configuration
on a mac as I don't have one or anyone who could check. The variable does exist though and on my linux system it has value "x86_64-pc-linux-gnu"
so it seems legit.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I think it's pretty safe to do it this way. I have several packages that do this, and I have no issues with them.
Examples:
- https://github.com/emacs-tree-sitter/tree-sitter-langs/blob/698a17da1f8e2bd34858ce46c727f492c69d123b/tree-sitter-langs-build.el#L274-L297
- https://github.com/jcs-elpa/flx-rs/blob/b47b9e9b6f17f21d46bbd0d28f408006d6ac2dd4/flx-rs.el#L74-L84
I'm running both packages on macOS M3.
(lsp-treemacs-render tree title 0 | ||
"*SQL Object explorer*" nil) | ||
(with-current-buffer "*SQL Object explorer*" | ||
(display-buffer-in-side-window (current-buffer) '((side . right))) | ||
(lsp-mssql-object-explorer-mode))) |
Copilot
AI
Sep 30, 2025
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
The indentation uses tabs instead of spaces, which is inconsistent with Emacs Lisp conventions. Use consistent space-based indentation.
Copilot uses AI. Check for mistakes.
;; - (with-current-buffer (get-buffer-create "*SQL Object explorer*") | ||
;; - (lsp-treemacs-initialize) | ||
;; - (setq-local lsp-treemacs-tree tree) | ||
;; - (setq-local face-remapping-alist '((button . default))) | ||
;; - (lsp-treemacs-generic-refresh);; - | ||
;; - (setq-local mode-name title) | ||
|
||
|
||
|
||
|
Copilot
AI
Sep 30, 2025
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Commented-out code should be removed rather than left in the source. If this code might be needed for reference, consider documenting the migration in a commit message instead.
;; - (with-current-buffer (get-buffer-create "*SQL Object explorer*") | |
;; - (lsp-treemacs-initialize) | |
;; - (setq-local lsp-treemacs-tree tree) | |
;; - (setq-local face-remapping-alist '((button . default))) | |
;; - (lsp-treemacs-generic-refresh);; - | |
;; - (setq-local mode-name title) |
Copilot uses AI. Check for mistakes.
Fixes issue 22 - #22