Skip to content

Commit 408197b

Browse files
author
elkaboussi
committed
rebrand to minibash
1 parent 73f760b commit 408197b

31 files changed

+39
-39
lines changed

.gitignore

+1-1
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
# MINISHEL
22
bin/
3-
minishell
3+
minibash
44
venv/
55
.vscode/
66
.idea/

Dockerfile

+1-1
Original file line numberDiff line numberDiff line change
@@ -8,5 +8,5 @@ COPY . .
88

99
RUN make
1010

11-
ENTRYPOINT ["./minishell"]
11+
ENTRYPOINT ["./minibash"]
1212

Makefile

+2-2
Original file line numberDiff line numberDiff line change
@@ -21,9 +21,9 @@ BIN_DIR = build/
2121
OBJS = $(SRCS:%.c=$(BIN_DIR)%.o)
2222
OBJS_DIRS = $(dir $(OBJS))
2323

24-
INCLUDES = includes/builtin.h includes/execution.h includes/minishell.h includes/parsing.h includes/helpers.h includes/utils.h
24+
INCLUDES = includes/builtin.h includes/execution.h includes/minibash.h includes/parsing.h includes/helpers.h includes/utils.h
2525

26-
NAME = minishell
26+
NAME = minibash
2727

2828

2929
all: $(NAME)

README.md

+2-2
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,7 @@
22
1. Install readline library and some extra dependencies
33
`sudo apt-get install lib32readline8 lib32readline-dev make git gcc`
44
2. Clone the repository
5-
`git clone https://github.com/fortytwobytes/minishell && cd minishell`
5+
`git clone https://github.com/fortytwobytes/minibash && cd minibash`
66
3. Compile and run the program
7-
`make && ./minishell`
7+
`make && ./minibash`
88

builtins/shell_exit.c

+1-1
Original file line numberDiff line numberDiff line change
@@ -10,7 +10,7 @@
1010
/* */
1111
/* ************************************************************************** */
1212

13-
#include "minishell.h"
13+
#include "minibash.h"
1414

1515
int is_all_num(char *s)
1616
{

execution/shell.c

+1-1
Original file line numberDiff line numberDiff line change
@@ -10,7 +10,7 @@
1010
/* */
1111
/* ************************************************************************** */
1212

13-
#include "minishell.h"
13+
#include "minibash.h"
1414

1515
static int is_space(char c);
1616
static void ft_add_history(char *line);

execution/signals.c

+1-1
Original file line numberDiff line numberDiff line change
@@ -10,7 +10,7 @@
1010
/* */
1111
/* ************************************************************************** */
1212

13-
#include "minishell.h"
13+
#include "minibash.h"
1414

1515
// rl_on_new_line : tells that we moved to a nl
1616
// rl_replace_line : replace the content of the rl buffer

includes/builtin.h

+1-1
Original file line numberDiff line numberDiff line change
@@ -13,7 +13,7 @@
1313
#ifndef BUILTIN_H
1414
# define BUILTIN_H
1515

16-
# include "minishell.h"
16+
# include "minibash.h"
1717

1818
int size_of_env(void);
1919
void index_envs(void);

includes/execution.h

+1-1
Original file line numberDiff line numberDiff line change
@@ -13,7 +13,7 @@
1313
#ifndef EXECUTION_H
1414
# define EXECUTION_H
1515

16-
# include "minishell.h"
16+
# include "minibash.h"
1717

1818
typedef struct s_envs t_envs;
1919
typedef struct s_cmd t_cmd;

includes/helpers.h

+1-1
Original file line numberDiff line numberDiff line change
@@ -13,7 +13,7 @@
1313
#ifndef SRCS_H
1414
# define SRCS_H
1515

16-
# include "minishell.h"
16+
# include "minibash.h"
1717

1818
int ft_open(char *path, int oflag, int mode);
1919
void ft_close(int fildes);

includes/minishell.h includes/minibash.h

+5-5
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
/* ************************************************************************** */
22
/* */
33
/* ::: :::::::: */
4-
/* minishell.h :+: :+: :+: */
4+
/* minibash.h :+: :+: :+: */
55
/* +:+ +:+ +:+ */
66
/* By: relkabou <[email protected]> +#+ +:+ +#+ */
77
/* +#+#+#+#+#+ +#+ */
@@ -10,8 +10,8 @@
1010
/* */
1111
/* ************************************************************************** */
1212

13-
#ifndef MINISHELL_H
14-
# define MINISHELL_H
13+
#ifndef MINIBASH_H
14+
# define MINIBASH_H
1515

1616
# include <stdio.h>
1717
# include <fcntl.h>
@@ -34,7 +34,7 @@
3434
# define TRUE 1
3535
# define FALSE 0
3636

37-
# define PROMPT "minishell $> "
37+
# define PROMPT "minibash $> "
3838

3939
# define READ 0
4040
# define WRITE 1
@@ -63,4 +63,4 @@ struct s_global
6363
};
6464

6565
void shell_loop(void);
66-
#endif // MINISHELL_H
66+
#endif // MINIBASH_H

includes/parsing.h

+1-1
Original file line numberDiff line numberDiff line change
@@ -13,7 +13,7 @@
1313
#ifndef PARSING_H
1414
# define PARSING_H
1515

16-
# include "minishell.h"
16+
# include "minibash.h"
1717

1818
# define EXIT_SYNTAX 258
1919

includes/utils.h

+1-1
Original file line numberDiff line numberDiff line change
@@ -13,7 +13,7 @@
1313
#ifndef UTILS_H
1414
# define UTILS_H
1515

16-
# include "minishell.h"
16+
# include "minibash.h"
1717

1818
/* ---------- MISC ------------ */
1919
int ft_atoi(char *str);

main.c

+1-1
Original file line numberDiff line numberDiff line change
@@ -10,7 +10,7 @@
1010
/* */
1111
/* ************************************************************************** */
1212

13-
#include "minishell.h"
13+
#include "minibash.h"
1414

1515
t_global g_global;
1616
void init_global(char **envp);

parsing/commands.c

+1-1
Original file line numberDiff line numberDiff line change
@@ -10,7 +10,7 @@
1010
/* */
1111
/* ************************************************************************** */
1212

13-
#include "minishell.h"
13+
#include "minibash.h"
1414

1515
// cat | ls | grep
1616
// during exucution infile and outfile should be closee

parsing/commands_list.c

+1-1
Original file line numberDiff line numberDiff line change
@@ -10,7 +10,7 @@
1010
/* */
1111
/* ************************************************************************** */
1212

13-
#include "minishell.h"
13+
#include "minibash.h"
1414

1515
void free_cmd(t_cmd *head)
1616
{

parsing/env.c

+1-1
Original file line numberDiff line numberDiff line change
@@ -10,7 +10,7 @@
1010
/* */
1111
/* ************************************************************************** */
1212

13-
#include "minishell.h"
13+
#include "minibash.h"
1414

1515
int is_env_name(char c)
1616
{

parsing/expand.c

+1-1
Original file line numberDiff line numberDiff line change
@@ -10,7 +10,7 @@
1010
/* */
1111
/* ************************************************************************** */
1212

13-
#include "minishell.h"
13+
#include "minibash.h"
1414

1515
// this function copies the token string into a new
1616
// allocated string without copying the -1 occurenccense=

parsing/expand_env.c

+1-1
Original file line numberDiff line numberDiff line change
@@ -10,7 +10,7 @@
1010
/* */
1111
/* ************************************************************************** */
1212

13-
#include "minishell.h"
13+
#include "minibash.h"
1414

1515
// this function returns the len of the variable name , exp : $abc => 4 , $ => 1
1616
// [A-Z]{1,}[A-Z0-9_]

parsing/free.c

+1-1
Original file line numberDiff line numberDiff line change
@@ -10,7 +10,7 @@
1010
/* */
1111
/* ************************************************************************** */
1212

13-
#include "minishell.h"
13+
#include "minibash.h"
1414

1515
void free_tokens(t_token *tokens)
1616
{

parsing/heredoc.c

+1-1
Original file line numberDiff line numberDiff line change
@@ -10,7 +10,7 @@
1010
/* */
1111
/* ************************************************************************** */
1212

13-
#include "minishell.h"
13+
#include "minibash.h"
1414

1515
int is_expand(char **limiter)
1616
{

parsing/heredoc_expansion.c

+1-1
Original file line numberDiff line numberDiff line change
@@ -10,7 +10,7 @@
1010
/* */
1111
/* ************************************************************************** */
1212

13-
#include "minishell.h"
13+
#include "minibash.h"
1414

1515
char *get_name_here(char *token)
1616
{

parsing/lexer.c

+1-1
Original file line numberDiff line numberDiff line change
@@ -10,7 +10,7 @@
1010
/* */
1111
/* ************************************************************************** */
1212

13-
#include "minishell.h"
13+
#include "minibash.h"
1414

1515
// a function that return the position of the next quote char
1616
int next_quote(int i, char quote, char *line)

parsing/operator.c

+1-1
Original file line numberDiff line numberDiff line change
@@ -10,7 +10,7 @@
1010
/* */
1111
/* ************************************************************************** */
1212

13-
#include "minishell.h"
13+
#include "minibash.h"
1414

1515
int is_operator(char c)
1616
{

parsing/parser.c

+2-2
Original file line numberDiff line numberDiff line change
@@ -10,10 +10,10 @@
1010
/* */
1111
/* ************************************************************************** */
1212

13-
#include "minishell.h"
13+
#include "minibash.h"
1414

1515
// this function checks if we have another type of operator except the ones
16-
// handled by our minishell
16+
// handled by our minibash
1717
int check_invalid_operator(t_token *tokens)
1818
{
1919
while (tokens)

parsing/parsing_utils.c

+1-1
Original file line numberDiff line numberDiff line change
@@ -10,7 +10,7 @@
1010
/* */
1111
/* ************************************************************************** */
1212

13-
#include "minishell.h"
13+
#include "minibash.h"
1414

1515
void open_pipes(t_token *tokens)
1616
{

parsing/token_list.c

+2-2
Original file line numberDiff line numberDiff line change
@@ -10,11 +10,11 @@
1010
/* */
1111
/* ************************************************************************** */
1212

13-
#include "minishell.h"
13+
#include "minibash.h"
1414

1515
// in this function we chose the type of passed string
1616
// the possible strings are sequences of operators or normal chars
17-
// if the sequence of operators is not to be handle by our minishell we name
17+
// if the sequence of operators is not to be handle by our minibash we name
1818
// it by the token OPERATOR which should syntax error
1919
// else the token are allowed
2020
int choose_token_type(char *s)

parsing/word_spliting.c

+1-1
Original file line numberDiff line numberDiff line change
@@ -10,7 +10,7 @@
1010
/* */
1111
/* ************************************************************************** */
1212

13-
#include "minishell.h"
13+
#include "minibash.h"
1414

1515
void init_values(int *flag, int *i, int *count, int *q)
1616
{

utils/ft_free.c

+1-1
Original file line numberDiff line numberDiff line change
@@ -10,7 +10,7 @@
1010
/* */
1111
/* ************************************************************************** */
1212

13-
#include "minishell.h"
13+
#include "minibash.h"
1414

1515
// a function that free split return : a 2d array of string terminated by NULL;
1616
void free_split(char **s)

utils/ft_itoa.c

+1-1
Original file line numberDiff line numberDiff line change
@@ -10,7 +10,7 @@
1010
/* */
1111
/* ************************************************************************** */
1212

13-
#include "minishell.h"
13+
#include "minibash.h"
1414

1515
static int ft_num_of_characters(int n, int *signe)
1616
{

utils/ft_substr.c

+1-1
Original file line numberDiff line numberDiff line change
@@ -10,7 +10,7 @@
1010
/* */
1111
/* ************************************************************************** */
1212

13-
#include "minishell.h"
13+
#include "minibash.h"
1414

1515
char *ft_substr(char *s, size_t start, size_t end)
1616
{

0 commit comments

Comments
 (0)