Skip to content

Commit 65b5f94

Browse files
pcloudsgitster
authored andcommitted
Move declaration for alias.c to alias.h
Signed-off-by: Nguyễn Thái Ngọc Duy <[email protected]> Signed-off-by: Junio C Hamano <[email protected]>
1 parent d9fcc7f commit 65b5f94

File tree

10 files changed

+17
-5
lines changed

10 files changed

+17
-5
lines changed

alias.c

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,5 @@
11
#include "cache.h"
2+
#include "alias.h"
23
#include "config.h"
34

45
struct config_alias_data {

alias.h

Lines changed: 9 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,9 @@
1+
#ifndef __ALIAS_H__
2+
#define __ALIAS_H__
3+
4+
char *alias_lookup(const char *alias);
5+
int split_cmdline(char *cmdline, const char ***argv);
6+
/* Takes a negative value returned by split_cmdline */
7+
const char *split_cmdline_strerror(int cmdline_errno);
8+
9+
#endif

builtin/help.c

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -9,6 +9,7 @@
99
#include "run-command.h"
1010
#include "column.h"
1111
#include "help.h"
12+
#include "alias.h"
1213

1314
#ifndef DEFAULT_HELP_FORMAT
1415
#define DEFAULT_HELP_FORMAT "man"

builtin/merge.c

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -34,6 +34,7 @@
3434
#include "string-list.h"
3535
#include "packfile.h"
3636
#include "tag.h"
37+
#include "alias.h"
3738

3839
#define DEFAULT_TWOHEAD (1<<0)
3940
#define DEFAULT_OCTOPUS (1<<1)

cache.h

Lines changed: 0 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -1835,11 +1835,6 @@ extern int ws_blank_line(const char *line, int len, unsigned ws_rule);
18351835
void overlay_tree_on_index(struct index_state *istate,
18361836
const char *tree_name, const char *prefix);
18371837

1838-
char *alias_lookup(const char *alias);
1839-
int split_cmdline(char *cmdline, const char ***argv);
1840-
/* Takes a negative value returned by split_cmdline */
1841-
const char *split_cmdline_strerror(int cmdline_errno);
1842-
18431838
/* setup.c */
18441839
struct startup_info {
18451840
int have_repository;

connect.c

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -13,6 +13,7 @@
1313
#include "transport.h"
1414
#include "strbuf.h"
1515
#include "protocol.h"
16+
#include "alias.h"
1617

1718
static char *server_capabilities;
1819
static const char *parse_feature_value(const char *, const char *, int *);

git.c

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -3,6 +3,7 @@
33
#include "exec_cmd.h"
44
#include "help.h"
55
#include "run-command.h"
6+
#include "alias.h"
67

78
#define RUN_SETUP (1<<0)
89
#define RUN_SETUP_GENTLY (1<<1)

pager.c

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -2,6 +2,7 @@
22
#include "config.h"
33
#include "run-command.h"
44
#include "sigchain.h"
5+
#include "alias.h"
56

67
#ifndef DEFAULT_PAGER
78
#define DEFAULT_PAGER "less"

sequencer.c

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -23,6 +23,7 @@
2323
#include "hashmap.h"
2424
#include "notes-utils.h"
2525
#include "sigchain.h"
26+
#include "alias.h"
2627

2728
#define GIT_REFLOG_ACTION "GIT_REFLOG_ACTION"
2829

shell.c

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -3,6 +3,7 @@
33
#include "exec_cmd.h"
44
#include "strbuf.h"
55
#include "run-command.h"
6+
#include "alias.h"
67

78
#define COMMAND_DIR "git-shell-commands"
89
#define HELP_COMMAND COMMAND_DIR "/help"

0 commit comments

Comments
 (0)