1
0
Fork 0
mirror of https://github.com/HackHerz/pusher synced 2025-12-06 02:10:19 +00:00

No boost dependencies anymore

This commit is contained in:
Daniel Stein 2015-01-26 16:34:18 +01:00
parent ab3c0b62df
commit ca3289de24
39 changed files with 13456 additions and 4467 deletions

View file

@ -1,56 +1,73 @@
<div style="text-align:center">![](http://hackherz.com/wp-content/uploads/2014/09/Pusher-UNIX.png)</div>
# pusher
**pusher** is a simple cli program to connect your server or computer with the app [PushNotifier](http://www.pushnotifier.de/).
Send push-notifications to your phone from the command line. Uses [PushNotifier](http://pushnotifier.de/) to receive notifications.
## Features
- Written in C++
- Easy to [install](https://github.com/hackherz/pusher#installation)
- Even easier to [use](https://github.com/hackherz/pusher#usage)
- Should work on all Unix-based systems
# Building
## Requirements
## Installation
* boost `libboost-dev`
* boost regex `libboost-regex-dev`
* boost program options `libboost-program-options-dev`
* curl `libcurl4-gnutls-dev`
### Option 1: Debian package
You can download debian packages from [my website](http://hackherz.com/pusher#download).
## Compile
First you do have to change `API_TOKEN` in src/pushhandler.h. You can receive your API-Token at [a.gidix.de](http://a.gidix.de/). Don't forget to match the APP-Package as well.
chmod +x configure
./configure
make
make install
If you want to uninstall `pusher` try
make remove
### Option 2: From source
```bash
$ git clone https://github.com/HackHerz/pusher.git
$ cd pusher/
$ make
$ make install
```
# Usage
## Usage
The first time using `pusher` you have to log in to your [gidix.de](http://www.gidix.de/) account.
### Basic usage
```bash
$ pusher -i 1 "Hello World" # Send Hello World to device-id 1
```
pusher -t
### Pipe output into pusher
```bash
$ echo "Hello World" | pusher -i 1 -p
```
### List all your devices
```bash
$ pusher --list
```
### Login
```bash
$ pusher --token # Only necessary the first time using pusher
```
### Display Help
```bash
$ pusher -h # Outputs all available options
```
The next step is to request a list of all your devices available
## Contributing
pusher -l
#### Bug Reports & Feature Requests
Please use the [issue tracker](https://github.com/HackHerz/pusher/issues) to report any bugs or file feature requests.
#### Developing
Just file a pull request and start coding.
You are finally able to send messages from your server to your device. You have two options now.
1) Normal mode.
Declare the message in " and put the message as your last argument.
pusher -i # "hello world"
Replace the `#` with the id of your device.
### Keeping me motivated
If you want to ensure that I'll continue developing just send me a tweet [@hackherz](https://twitter.com/hackherz) why you like or use my software :).
2) Pipe mode.
You can pipe the output of another program, e.g. echo, into `pusher`
## Libraries
pusher uses a few third party libraries. They are all MIT-Licensed but they are so awesome I have to mention them.
echo "hello world" | pusher -i # -p
To see more available options use the help flag.
pusher -h
- [json](https://github.com/nlohmann/json) by [Niels Lohmann](http://nlohmann.me/)
- [TCLAP](http://tclap.sourceforge.net/)
- [simpleini](https://github.com/brofield/simpleini) by Brodie Thiesfield