Sailslack2

Rating: 
5
Your rating: None Average: 5 (2 votes)

Unofficial opensource Slack client for Sailfish.

SailSlack2 is a fork of SailSlack by danvratil.

This is an alpha-quality software, do NOT rely on it for work!

I do not plan to do any further development but forked since I couldn't get in contact with maintainer for the Sailslack app when I wanted to merge fixes for some bugs.

Features:

  • multiple teams support
  • channels, private chats and multi-user chats
  • real-time messaging and notifications
  • sending messages and images
  • display sender's detailed profile

Currently not implemented/broken

  • joining channels and chats from the app
  • viewing and replying to threads (you see all the messages but as a flat list)
  • reacting to messages
  • starring channels, messages etc.
  • creating reminders
  • search
  • message deletion or editing from the app

Source code: https://github.com/decon4/harbour-sailslack

License: GPLv3

Workaround for not being able to login

The problem with the login is due to Qt WebView being to old to handle the login page provided by Slack and it is a bit difficult to fix that in the app without a newer Qt version.

I have however found a workaround (which can be used until Jolla decides to upgrade Qt):
1. Log in to phone via ssh
2. Insert the following as root (devel-su) before last "}" in /usr/share/harbour-sailslack/qml/pages/LoginPage.qml and save file. Sorry about formatting. Couldn't find a way to insert as 'code'.

    property url tmpUrl: "https://localhost:3000/oauth/callback?code="
    Component.onCompleted: {
        console.log("startUrl", startUrl)
        //authenticator.fetchAccessToken(page.tmpUrl)
    }

3. start app from CLI and select "Sign into a Workspace" from pulldown:
harbour-sailslack
4. Kill app (ctrl-c)
5. Locate debug print "startUrl" and paste the url to your browser on pc
6. After you have logged in to slack on your pc and pressed the accept button it will redirect to another url. Store this url in a text editor.
7. The redirect url contains a long code containg hex numbers and dots. (look after "code=")
8. Insert this code after "code=" in property tmpUrl in LoginPage.qml. (The code is only valid for 10 minutes but you can call the startUrl in the browser again if you are too slow.)
9. Uncomment authenticator.fetchAccessToken(page.tmpUrl) (i.e. remove //) and save file.
10. Start app again and it will fetch your workspace data automatically.

Screenshots: 
Application versions: 
AttachmentSizeDate
File harbour-sailslack2-0.1-1.armv7hl.rpm186.43 KB25/07/2020 - 12:54
File harbour-sailslack2-0.1-2.armv7hl.rpm186.43 KB28/07/2020 - 11:21
Changelog: 

* 0.1-2
- Added https for login callback link

* 0.1-1
- Forked from harbour-sailslack
- Fixed images not being loaded
- Ported some API calls to new conversations API

 

Comments

muppis's picture

Thank you for fixing this. I managed to sign in using FingerTerm and Firefox Lite for Android. Any browser for Android should do the trick.

  1. Open FingerTerm and logged in as root using devel-su -command
  2. Open required file to nano and add required code block as mentioned. Note: For me either FignerTerm or nano messed up the paste and } -mark jumped to wrong place. Check it!
  3. Save file with ctrl-o
  4. Remove comment marks ( // ) and URL from pasted section. Do not save at this point!
  5. Open second FingerTerm (from 1st FingerTerm menus) and launch Sailslack2 from it.
  6. Selected Sign into a Workplace from Sailslack2's menu.
  7. Switch back to second FingerTerm (where you launched Sailslack2) and press ctrl-c
  8. Use FingerTerm URL grabber to get URL, should be only one in terminal.
  9. Paste URL to Firefox Lite and sign in.
  10. Copy URL (https://localhost...) from Firefox Lite's addressbar
  11. Paste URL to nano in 1st FingerTerm window.
  12. Check layout of line where URL should be. Nano is known doing line wrapping with long lines, which breaks file the layout.
  13. You can quit the nano (ctrl-x) or just save the file with ctrl-o
  14. Launch Sailslack2 from launcher and try Sign into a Workplace. You should automatically sign in.
naytsyrhc's picture

Unfortunately the mentioned trick to login doesn't work for me. I get the following error from slack directly after trying to request the copied startUrl:
invalid_team_for_non_distributed_app

decon's picture

It will hopefully work better with version 0.1-2 of app (I have tested with two separate workspaces). I had to change callback link to use https so the workaround had to be updated. I have added the updated workaround in description above.

cartron's picture

what did you exactly fix as bugs compared to Sailslack? Would be nice to know - maybe add it in the app description?

decon's picture

Fixed!