Skip to content

Commit

Permalink
Make & Doc: Add make install
Browse files Browse the repository at this point in the history
  • Loading branch information
spmzt committed Aug 2, 2024
1 parent 5c78de2 commit bfec201
Show file tree
Hide file tree
Showing 3 changed files with 32 additions and 2 deletions.
19 changes: 17 additions & 2 deletions Makefile
Original file line number Diff line number Diff line change
@@ -1,8 +1,23 @@
all:
OS= $$(uname -o)

.PHONY: depends
depends:
@echo "Install Dependencies"
@if [ -e /etc/debian_version ]; then\
dpkg -s libcurl4-openssl-dev &>/dev/null || DEBIAN_FRONTEND=noninteractive apt install -y libcurl4-openssl-dev;\
fi

build: depends
cc ssh-import-id.c -L/usr/local/lib -lcurl -I/usr/local/include -Wall -Wextra -Werror -o ssh-import-id

install: build
cp ssh-import-id /usr/local/bin/

debug:
cc -g ssh-import-id.c -L/usr/local/lib -lcurl -I/usr/local/include -Wall -Wextra -Werror -o ssh-import-id

clean:
rm ssh-import-id ssh-import-id-gh ssh-import-id-lp
rm -f ssh-import-id ssh-import-id-gh ssh-import-id-lp

uninstall: clean
rm /usr/local/bin/ssh-import-id
15 changes: 15 additions & 0 deletions README.md
Original file line number Diff line number Diff line change
@@ -1,11 +1,25 @@
# ssh-import-id

ssh-import-id written in C language

## Installation

### GitHub

To get started with the project, follow these steps:

```sh
git clone https://github.com/spmzt/ssh-import-id.git
cd ssh-import-id
make install
```

## Contributions

Any PR(s) are welcomed.

## TODO

- ~~add -u flag for useragent~~
- ~~add launchpad provider~~
- ~~add -t flag for truncate (overwrite current keys)~~
Expand All @@ -15,4 +29,5 @@ Any PR(s) are welcomed.
- add capability to understand x_ratelimit_remaining header for github

## Known Issues

- Currently, User-Agent option is only supported 16 characters which is too short for most real User-Agents.
Binary file added ssh-import-id
Binary file not shown.

0 comments on commit bfec201

Please sign in to comment.