Add ability to specify address in default.project.json (#507)

* Allow for setting the default port in project json

set as
```json
"serveAddress": "0.0.0.0"
```

* Update CHANGELOG.md

* cargo fmt

Co-authored-by: Lucien Greathouse <me@lpghatguy.com>
This commit is contained in:
Ashton Miller
2022-04-19 15:54:03 -05:00
committed by GitHub
parent 12370846b4
commit 49f8845105
4 changed files with 19 additions and 2 deletions

View File

@@ -2,6 +2,7 @@ use std::{
borrow::Cow,
collections::HashSet,
io,
net::IpAddr,
path::{Path, PathBuf},
sync::{Arc, Mutex, MutexGuard},
time::Instant,
@@ -212,6 +213,10 @@ impl ServeSession {
pub fn serve_place_ids(&self) -> Option<&HashSet<u64>> {
self.root_project.serve_place_ids.as_ref()
}
pub fn serve_address(&self) -> Option<IpAddr> {
self.root_project.serve_address
}
}
#[derive(Debug, Error)]