Comments (3)
Good point about pulling out the condition. I have done that now and made a release 1.9. That part of the code isn't very elegant...
Implemented a really simple support for just Host *
now. Hopefully that will fulfill some people's needs. Didn't have time to do a full fledged version for things like
Host *.example.com
Host *.example.*
Host somehost.*.com
Match host host1.com,host2.com
Those would be nice to have in the future.
from filesremote.
Might be as simple as just adding something like || cur_host == "*"
to each of the conditions
} else if (cmd == "hostname" && (cur_host == this->display_host_ || cur_host.empty())) {
...
} else if (cmd == "identityfile" && (cur_host == this->display_host_ || cur_host.empty())) {
...
} else if (cmd == "user" && !username_given && (cur_host == this->display_host_ || cur_host.empty())) {
...
} else if (cmd == "port" && !port_given && (cur_host == this->display_host_ || cur_host.empty())) {
near https://github.com/allanrbo/filesremote/blob/master/src/hostdesc.cpp#L139
from filesremote.
I've been looking at this place, but was not absolutely sure that I understand how it works. Is there any strong reason why we can't extract the cur_host == this->display_host_ || cur_host.empty() || ...
part into a local variable defined right before the if/else cascade?
from filesremote.
Related Issues (19)
- SSH Key Authentication HOT 6
- Libssh2_session_handshake failed. Invalid MAC received. HOT 9
- MacOS makes it hard to open new window HOT 1
- libssh2_sftp_init hangs when connecting to OpenWRT with Dropbear SSH server HOT 1
- Release MacOS arm HOT 1
- ProxyJump HOT 1
- will there be a flatpack version of the app? HOT 2
- Right click doesn't work (Linux) HOT 2
- Agent doesnt seem to work when connecting to Debian 12 hosts HOT 2
- Window don't have size after startup computer (Win 10/11)
- windows is flagging as virus HOT 3
- Enhancement Request: Custom Editors for Different File Types HOT 1
- configurable temporary folder path.
- Please add option for password in CLI HOT 6
- Align use of `.ssh/config` better with the openssh client HOT 2
- Drag-n-Drop Support? HOT 7
- Freezes in Windows if remote server disconnected HOT 3
- filesremote window has no size | macos HOT 2
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
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.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from filesremote.