Skip to content

Commit

Permalink
Issue a warning if no partitions are specified during serve.
Browse files Browse the repository at this point in the history
Closes #40
  • Loading branch information
LPGhatguy committed May 22, 2018
1 parent b067335 commit aa5f0cc
Show file tree
Hide file tree
Showing 2 changed files with 8 additions and 0 deletions.
1 change: 1 addition & 0 deletions CHANGES.md
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,7 @@

## Current master
* Added icons to the Rojo plugin, made by [@Vorlias](https://github.com/Vorlias)! ([#70](https://github.com/LPGhatguy/rojo/pull/70))
* Server will now issue a warning if no partitions are specified in `rojo serve` ([#40](https://github.com/LPGhatguy/rojo/issues/40))

## 0.4.6 (May 21, 2018)
* Rojo handles being restarted by Roblox Studio more gracefully ([#67](https://github.com/LPGhatguy/rojo/issues/67))
Expand Down
7 changes: 7 additions & 0 deletions server/src/commands/serve.rs
Original file line number Diff line number Diff line change
Expand Up @@ -44,6 +44,13 @@ pub fn serve(project_path: &PathBuf, verbose: bool, port: Option<u64>) {
},
};

if project.partitions.len() == 0 {
println!("");
println!("This project has no partitions and will not do anything when served!");
println!("This is usually a mistake -- edit rojo.json!");
println!("");
}

lazy_static! {
static ref PLUGIN_CHAIN: PluginChain = PluginChain::new(vec![
Box::new(ScriptPlugin::new()),
Expand Down

0 comments on commit aa5f0cc

Please sign in to comment.