@ -256,7 +256,7 @@ void Window::set_menu_actions() {
}
std : : string cmakelists = " cmake_minimum_required(VERSION 2.8) \n \n project( " + project_name + " ) \n \n set(CMAKE_C_FLAGS \" ${CMAKE_C_FLAGS} -std=c11 -Wall -Wextra \" ) \n \n add_executable( " + project_name + " main.c) \n " ;
std : : string c_main = " #include <stdio.h> \n \n int main() { \n printf( \" Hello World! \\ n \" ); \n } \n " ;
std : : string clang_format = " IndentWidth: 2 \n AccessModifierOffset: -2 \n UseTab: Never \n ColumnLimit: 0 \n MaxEmptyLinesToKeep: 2 \n SpaceBeforeParens: Never \n BreakBeforeBraces: Custom \n BraceWrapping: {BeforeElse: true, BeforeCatch: true} \n " ;
std : : string clang_format = " IndentWidth: 2 \n AccessModifierOffset: -2 \n UseTab: Never \n ColumnLimit: 0 \n MaxEmptyLinesToKeep: 2 \n BreakBeforeBraces: Custom \n BraceWrapping: {BeforeElse: true, BeforeCatch: true} \n " ;
if ( filesystem : : write ( cmakelists_path , cmakelists ) & & filesystem : : write ( c_main_path , c_main ) & & filesystem : : write ( clang_format_path , clang_format ) ) {
Directories : : get ( ) . open ( project_path ) ;
Notebook : : get ( ) . open ( c_main_path ) ;
@ -292,7 +292,7 @@ void Window::set_menu_actions() {
}
std : : string cmakelists = " cmake_minimum_required(VERSION 2.8) \n \n project( " + project_name + " ) \n \n set(CMAKE_CXX_FLAGS \" ${CMAKE_CXX_FLAGS} -std=c++1y -Wall -Wextra \" ) \n \n add_executable( " + project_name + " main.cpp) \n " ;
std : : string cpp_main = " #include <iostream> \n \n int main() { \n std::cout << \" Hello World! \\ n \" ; \n } \n " ;
std : : string clang_format = " IndentWidth: 2 \n AccessModifierOffset: -2 \n UseTab: Never \n ColumnLimit: 0 \n MaxEmptyLinesToKeep: 2 \n SpaceBeforeParens: Never \n BreakBeforeBraces: Custom \n BraceWrapping: {BeforeElse: true, BeforeCatch: true} \n NamespaceIndentation: All \n " ;
std : : string clang_format = " IndentWidth: 2 \n AccessModifierOffset: -2 \n UseTab: Never \n ColumnLimit: 0 \n MaxEmptyLinesToKeep: 2 \n BreakBeforeBraces: Custom \n BraceWrapping: {BeforeElse: true, BeforeCatch: true} \n NamespaceIndentation: All \n " ;
if ( filesystem : : write ( cmakelists_path , cmakelists ) & & filesystem : : write ( cpp_main_path , cpp_main ) & & filesystem : : write ( clang_format_path , clang_format ) ) {
Directories : : get ( ) . open ( project_path ) ;
Notebook : : get ( ) . open ( cpp_main_path ) ;