-
Notifications
You must be signed in to change notification settings - Fork 6
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
Showing
10 changed files
with
97 additions
and
12 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -2,3 +2,4 @@ | |
**/*.rs.bk | ||
.idea | ||
Cargo.lock | ||
themes/ |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,26 @@ | ||
use dirs; | ||
use std::fs; | ||
use std::process::Command; | ||
|
||
fn main() { | ||
println!("Starting to build Illumination."); | ||
println!("Fetching default themes."); | ||
|
||
Command::new("sh") | ||
.args(&["build/themes.sh"]) | ||
.status() | ||
.expect("Error fetching default themes"); | ||
|
||
let illumination_config_dir = format!( | ||
"{}/illumination/", | ||
dirs::config_dir().unwrap().to_str().unwrap() | ||
); | ||
|
||
println!("Copying themes to user config dir."); | ||
fs::create_dir_all(&illumination_config_dir).unwrap(); | ||
|
||
Command::new("cp") | ||
.args(&["-R", "themes", &illumination_config_dir]) | ||
.status() | ||
.expect("Error moving themes to user config dir"); | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,8 @@ | ||
mkdir -p .local/share/nvim/site/plugin/ | ||
mv neovim/illumination .local/share/nvim/site/plugin/illumination.vim | ||
mkdir -p themes/default | ||
curl -X GET https://cdnjs.cloudflare.com/ajax/libs/highlight.js/9.15.10/highlight.min.js > themes/default/hljs.min.js | ||
curl -X GET https://cdnjs.cloudflare.com/ajax/libs/highlight.js/9.12.0/languages/rust.min.js > themes/default/hljs-rust.js | ||
curl -X GET https://cdnjs.cloudflare.com/ajax/libs/highlight.js/9.15.10/styles/default.min.css > themes/default/hljs.min.css | ||
curl -X GET https://gist.githubusercontent.com/ryangray/1882525/raw/2a6e53f645b960f0bed16d686ba3df36505f839f/buttondown.css > themes/default/style.css | ||
curl -X GET https://cdnjs.cloudflare.com/ajax/libs/highlight.js/9.12.0/styles/github.min.css > themes/github.css |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,2 +1,2 @@ | ||
theme = "github" | ||
theme = "default" | ||
note-directory = "/home/okno/_Workshop/Notes" |
File renamed without changes.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,26 @@ | ||
use std::path::Path; | ||
use std::env; | ||
use self::Theme::*; | ||
use std::fs; | ||
use dirs; | ||
|
||
pub enum Theme { | ||
Bootstrap | ||
} | ||
|
||
impl Theme { | ||
fn path(self) -> String { | ||
let home = env::var("HOME").unwrap_or_else(|_| panic!("Unable to locate home directory")); | ||
match self { | ||
Bootstrap => format!("{}/.config/illumination/themes/boostrap", home) | ||
} | ||
} | ||
|
||
pub fn rel_path(self) { | ||
|
||
let current = fs::canonicalize(Path::new("./")).expect("maeoimoireza"); | ||
println!("{:?}", current); | ||
let abs_path = Path::new(&self.path()); | ||
|
||
} | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters