Coder Social home page Coder Social logo

rust-win32's Introduction

Learn to build win32 apps with Rust

This repository contains source code to some example projects in win32. I'm learning rust at the moment and this is a catalogue of my journey. Hopefully it will be useful to you dear reader.

Setting up your development environment

I'd recommend using chocolatey as your package manager.

To install rust,

  1. Run Powershell or Cmd with administrator privileges.
  2. Run choco install rust to install rust.
  3. Then, run choco install rustup.install to install rustup. It installs rustfmt which is a code formatter for rust.

Setting up your IDE

vscode

If you are using vscode, I'd recommend installing the rust-analyzer extension.

vim

If you are running vim, I'd recommend installing the [rust-lang/rust.vim](https://github.com/rust-lang/rust.vim) plugin

Running the examples

The examples are organised in their self-contained folder. All files needed to build and run the examples are in that folder.

To build an example, navigate to the folder in powershell / cmd and type

cargo build

To run the example, type

cargo run

For instance, to run the messagebox example,

PS C:\Code\rust-win32\examples\messagebox> cargo build
    Compiling messagebox v0.1.0 (C:\Code\rust-win32\examples\messagebox)
     Finished dev [unoptimized + debuginfo] target(s) in 1.04s
PS C:\Code\rust-win32\examples\messagebox> cargo run
    Finished dev [unoptimized + debuginfo] target(s) in 0.01s
     Running `target\debug\messagebox.exe`
PS C:\Code\rust-win32\examples\messagebox> 

Questions?

If you have any questions, please open an issue.

rust-win32's People

Contributors

pravin avatar

Watchers

 avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.