Giter Site home page Giter Site logo

jotavare / minitalk Goto Github PK

View Code? Open in Web Editor NEW
8.0 1.0 1.0 1.32 MB

System that sends a message from client to server using UNIX signals for communication.

License: MIT License

Makefile 5.25% C 94.75%
c minitalk signals unix ascii binary bits client-server gdb makefile

minitalk's Introduction

Linkedin 42

AboutHow to useMandatoryBonusNorminetteContributingLicense

ABOUT

This is a server/client system that uses UNIX signals for communication. The server displays its PID and receives decrypted signals as characters, while the client encrypts messages and sends true/false signals using SIGUSR1 or SIGUSR2 to the server's PID.

HOW TO USE

1º - Clone the repository

git clone https://github.com/jotavare/minitalk

2º - Enter the project folder and run make

cd minitalk/minitalk
make

3º - Run server or server_bonus and copy its PID

./server
./server_bonus

4º - Open another terminal, run client or client_bonus, paste the PID and write a message

./client [SERVER PID] [MESSAGE]
./client_bonus [SERVER PID] [MESSAGE] [EMOTE]

MAKEFILE RULES

make - Compile minitalk mandatory files.

make bonus - Compile minitalk bonus files.

make all - Compile mandatory + bonus files.

make clean - Delete all .o (object files) files.

make fclean - Delete all .o (object files) and .a (executable) files.

make re - Use rules fclean + all.

MANDATORY

  • Produce server and client executables.
  • The Client must communicate a string passed as a parameter to the server (referenced by its process ID) and display it.
  • Use SIGUSR1 and SIGUSR2 signals only.

BONUS

  • Add reception acknowledgement system.
  • Support Unicode characters.

NORMINETTE

At 42 School, it is expected that almost every project is written following the Norm, which is the coding standard of the school.

- No for, do...while, switch, case, goto, ternary operators, or variable-length arrays allowed;
- Each function must be a maximum of 25 lines, not counting the function's curly brackets;
- Each line must be at most 80 columns wide, with comments included;
- A function can take 4 named parameters maximum;
- No assigns and declarations in the same line (unless static);
- You can't declare more than 5 variables per function;
- ...
  • 42 Norms - Information about 42 code norms. PDF
  • Norminette - Tool to respect the code norm, made by 42. GitHub
  • 42 Header - 42 header for Vim. GitHub

CONTRIBUTING

If you find any issues or have suggestions for improvements, feel free to fork the repository and open an issue or submit a pull request.

LICENSE

This project is available under the MIT License. For further details, please refer to the LICENSE file.

minitalk's People

Contributors

jotavare avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar

Forkers

mazen-tech

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.