Fchat is a CLI chat application with support for channels and sending files.
Pre-requirements:
- Java 17 installed
JAVA_HOME
set to the location of your Java installation
The installation procedure:
- Download the latest release from here.
- Unpack it to any folder you wish.
- Add
bin/
folder to yourPATH
. - Restart the computer or restart explorer in the task manager.
- Open a terminal and try using
fchat
command. If the installation was successful you should see a command list.
Create a new directory and open a new terminal window there.
mkdir fchat
cd fchat
Run fchat init
command. This should create an fchat.properties
file inside the folder.
#Sat Mar 19 17:58:52 CET 2022
server_host=localhost
server_port=1337
username=Guest
Now edit the configuration to your preferences. Save the file, your client is now ready to use. You can have multiple clients in a separate directories.
Creates a fchat.properties file in the current directory.
fchat init
Creates a new group channel. You can use cd
command to enter the channel. Other users must use fchat sync
to see the
channel.
fchat create [name] (usernames...)
e.g. fhcat create "Small Talks" ben steven
- name - a name of the channel
- usernames - 0 or more usernames of users who should be added to the channel
Creates a new private channel. You can use cd
command to enter the channel. The other user must use fchat sync
to
see the channel.
fchat priv [username]
e.g. fchat priv christine
- username - a username of a user you want to chat with
Updates the channels list.
fchat sync
Sends a message to a channel. To use the command you have to first cd
to a channel directory.
fchat send [message...]
e.g. fchat send Hello Threre!
Reads a messages from a channel. To use the command you have to first cd
to a channel directory.
fchat read (count)
- a count of last messages to read
Sends a file to a channel. To use the command you have to first cd
to a channel directory.
fchat sendfile [path]
- path - a path of a file to send
Downloads a file from a channel. The file will be saved in the current directory. To use the command you have to
first cd
to a channel directory.
fchat download [name]
- a name of a file to download
In order to run the server locally:
- Clone the repository
- Run
./gradlew server:run
- A default server port is 1337. It can be changed using a
PORT
environmental variable