Subject | Hash | Author | Date (UTC) |
---|---|---|---|
working on example | 82a1df4d3f6c5e5405eae35f277572fc51b9a947 | mucbuc | 2020-08-23 20:02:57 |
remove spaces | 3085884efad6701037ead5fafc816e1e061f4f3e | mucbuc | 2020-08-23 19:47:11 |
template | f8b6264b7697735f0aaf9b5b7de16390c8388fb2 | mucbuc | 2020-08-23 17:05:05 |
wtf | 570de7c742cf9b3ec5518499fcbf87cd32902ebe | mucbuc | 2020-08-23 00:48:47 |
wtf | dfdd90a77db18e6c9778d88d7a167e5999ac81b7 | mucbuc | 2020-08-23 00:47:50 |
wtf | 8d1b6e0c8ec4d2363e1984941718ebd30bdecfcf | mucbuc | 2020-08-23 00:47:24 |
wtf | 0beeddd90c2545f4f66e26acdfc444d3f359c56a | mucbuc | 2020-08-23 00:46:43 |
what | 40e6ec7d104098b0e673be8f81c945c93f6ee13e | mucbuc | 2020-08-23 00:45:16 |
installJrnl linted | 99a721a40295ec2aa555e7ee27cd808b5d44a2c3 | mucbuc | 2020-08-23 00:42:33 |
config | 8d0e58c52406c09c861d376bba353467837edf4a | mucbuc | 2020-08-22 00:04:25 |
cleanup | 6db42918c86196075fe0b4047b3af6bdea98bde9 | mucbuc | 2020-08-21 19:20:23 |
test | 6c086247500a2158a41a5d9cbe037d0b3933e99e | mucbuc | 2020-08-21 18:59:40 |
fixes for zsh | adf6eae26569cac8c0487c0d7d62549ee2ac3df4 | mucbuc | 2020-08-19 04:54:15 |
ggSemver | aeb7c2eacf3a4f96a543b98dad9d96a45741a067 | mucbuc | 2020-07-31 18:03:35 |
install fzf | 1a5c8887ffe61c1a0699c48e6c5b6f756811f953 | mucbuc | 2020-07-26 10:59:24 |
move utils into base | 4215714e30c44cd28b99a47b9809c379b5a6f5b1 | mucbuc | 2020-07-25 11:14:02 |
single branch | 4e7951ffa4679e6aede7e41e9bb8afcc256cfdbe | mucbuc | 2020-07-25 04:11:11 |
install minpac | ea2855da3c825616fbf41621caabe93ff6952651 | mucbuc | 2020-07-25 04:04:25 |
fix symlink direction | 58c6f88e75de4b660aa5d1635d6ed30722531c10 | mucbuc | 2020-07-24 14:55:46 |
working on symlinking dot files | 4776a043a739cb668621575853090fd3169d49b1 | mucbuc | 2020-07-24 14:44:31 |
File | Lines added | Lines deleted |
---|---|---|
res/example.cpp.bp | 12 | 0 |
templates.js | 20 | 3 |
File res/example.cpp.bp added (mode: 100644) (index 0000000..11132f6) | |||
1 | #include <tmp/src/test.h> | ||
2 | |||
3 | #include <lib/${name}/src/index.h> | ||
4 | |||
5 | using namespace std; | ||
6 | using namespace om636::${name}; | ||
7 | |||
8 | int main() | ||
9 | { | ||
10 | ASSERT(0 && "fail"); | ||
11 | return 0; | ||
12 | } |
File templates.js changed (mode: 100755) (index d625343..2f6007e) | |||
1 | 1 | #!/usr/bin/env node | #!/usr/bin/env node |
2 | 2 | ||
3 | 3 | const { exec, pushd } = require( 'shelljs' ), | const { exec, pushd } = require( 'shelljs' ), |
4 | path = require( 'path' ); | ||
4 | path = require( 'path' ), | ||
5 | fs = require( 'fs' ), | ||
6 | vm = require( 'vm' ); | ||
5 | 7 | ||
6 | makeDirs(); | ||
8 | //makeTestDirs(); | ||
9 | generateExample("sample"); | ||
7 | 10 | ||
8 | function makeDirs() { | ||
11 | function generateExample(name) { | ||
12 | const exampleTemplate = 'var result = `' + fs.readFileSync('./res/example.cpp.bp', 'utf8' ) + '`;'; | ||
13 | const context = { name: "sample" }; | ||
14 | |||
15 | console.log( exampleTemplate ); | ||
16 | |||
17 | vm.createContext(context); | ||
18 | vm.runInContext(exampleTemplate, context); | ||
19 | |||
20 | console.log(context.result); | ||
21 | } | ||
22 | |||
23 | |||
24 | |||
25 | function makeTestDirs() { | ||
9 | 26 | const basename = path.basename( __dirname ); | const basename = path.basename( __dirname ); |
10 | 27 | ||
11 | 28 | exec( 'mkdir -p test/lib/' ); | exec( 'mkdir -p test/lib/' ); |