commit 8dcabfbf119db098405fcb5a9203c7aac124e298 Author: fitel17112 Date: Tue Mar 4 19:49:54 2025 +0530 001 diff --git a/.editorconfig b/.editorconfig new file mode 100644 index 0000000..01072ca --- /dev/null +++ b/.editorconfig @@ -0,0 +1,8 @@ +[*] +charset = utf-8 +end_of_line = lf +insert_final_newline = true +trim_trailing_whitespace = true + +[*.v] +indent_style = tab diff --git a/.gitattributes b/.gitattributes new file mode 100644 index 0000000..9a98968 --- /dev/null +++ b/.gitattributes @@ -0,0 +1,8 @@ +* text=auto eol=lf +*.bat eol=crlf + +*.v linguist-language=V +*.vv linguist-language=V +*.vsh linguist-language=V +v.mod linguist-language=V +.vdocignore linguist-language=ignore diff --git a/.gitignore b/.gitignore new file mode 100644 index 0000000..14222cc --- /dev/null +++ b/.gitignore @@ -0,0 +1,24 @@ +# Binaries for programs and plugins +main +air_bookings +*.exe +*.exe~ +*.so +*.dylib +*.dll + +# Ignore binary output folders +bin/ + +# Ignore common editor/system specific metadata +.DS_Store +.idea/ +.vscode/ +*.iml + +# ENV +.env + +# vweb and database +*.db +*.js diff --git a/src/main.v b/src/main.v new file mode 100644 index 0000000..51901fd --- /dev/null +++ b/src/main.v @@ -0,0 +1,23 @@ +module main + +import veb + +pub struct Context { + veb.Context +} + +pub struct App { + veb.StaticHandler +} + +pub fn (app &App) index(mut ctx Context) veb.Result { + return ctx.text('Namaste India!!!') +} + +fn main() { + mut app := &App{} + + app.handle_static('static', false)! + + veb.run[App, Context](mut app, 8080) +} diff --git a/v.mod b/v.mod new file mode 100644 index 0000000..469a399 --- /dev/null +++ b/v.mod @@ -0,0 +1,7 @@ +Module { + name: 'air_bookings' + description: 'An Air Plane Booking Web Application' + version: '0.0.0' + license: 'MIT' + dependencies: [] +}