• Activity
  • Votes
  • Comments
  • New
  • All activity
    1. What have you been listening to this week?

      What have you been listening to this week? You don't need to do a 6000 word review if you don't want to, but please write something! If you've just picked up some music, please update on that as...

      What have you been listening to this week? You don't need to do a 6000 word review if you don't want to, but please write something! If you've just picked up some music, please update on that as well, we'd love to see your hauls :)

      Feel free to give recs or discuss anything about each others' listening habits.

      You can make a chart if you use last.fm:

      http://www.tapmusic.net/lastfm/

      Remember that linking directly to your image will update with your future listening, make sure to reupload to somewhere like imgur if you'd like it to remain what you have at the time of posting.

      17 votes
    2. Animating the Inanimate Poetry Challenge

      @cadadr's 4 word poetry challenge is one of my favorite Tildes threads to read through on account of the many clever and thoughtful responses, so I figured I'd try to kick off another one. This...

      @cadadr's 4 word poetry challenge is one of my favorite Tildes threads to read through on account of the many clever and thoughtful responses, so I figured I'd try to kick off another one. This one is a little more conceptually involved, but I think it still has the potential to be a good time like the last one.

      Rather than going with a strict word or line count, instead I am creating a restriction based around personification:

      Challenge:
      Your poem must:

      • Be written from the point of view of an inanimate object
      • Give the object personality/emotion
      • NOT name the object, so that people have to infer it from what you've written

      An example might be an automatic door that is bored to tears from opening and closing ad nauseum. Or maybe a watering can that is excited to tend to its garden.

      In trying to come up with a model I decided to channel a resentful milk carton:

      It's fine
      I get it
      You don't have to justify yourself
      Lots of better things have come around
      Since you first chose me

      Just know that I'm still here
      If you need me
      Waiting for that blissful moment
      Where you light up my world
      And take me in your hand
      And make me feel like I'm flying
      Before you lower me down
      In a lover's embrace

      It's fine
      I get it
      Until then I'll sit here
      In the cold, cold dark
      Trying not to go sour
      Next to the slowly molding cheese
      And forgotten grapes

      It's far from perfect but hopefully it gives you an idea of what the assignment can look like. While I saved my "reveal" to the end, don't feel obligated to use that tactic unless you want to. You don't have to hide the identity of your object, just don't name the object outright in the poem.

      Feel free to make your poem as long or short as you wish. Feel free to make it as meaningful or silly as you want. Above all else, have fun!


      If you need help with ideas or just want the challenge of writing to a randomly selected specification, you can use this noun generator for objects and this adjective generator for sentiments.

      9 votes
    3. Having issues setting goals and sticking with them? I’m working on a solution

      I am working on an app called Percent Done that is a combination of goal setting, time tracking and habit tracking. I like setting time-based goals for myself every day, such as “write for an...

      I am working on an app called Percent Done that is a combination of goal setting, time tracking and habit tracking.

      I like setting time-based goals for myself every day, such as “write for an hour” or “work on Percent Done for four hours.”

      I also like Seinfeld’s “don’t break the chain” method. For example, Apple Watch shows you how many days you have completed your exercise circle and tells you that you have been keeping at it for x days.

      Percent Done is a marriage of these two concepts. It allows you to set goals and track the time you spend on them, as well as how many days in a row you have consistently completed them. For example, you can add a goal that says “write for an hour every day,” and Percent Done will notify you every day to write for an hour. You will be able to tap on this goal and Percent Done will start counting back from one hour. You will also be able to see how many days in a row you have written for an hour.

      Here is a demo GIF.

      You can also add one-time goals to Percent Done with or without time tracking, so it is a task management tool as well.

      You can play with the design prototype here: Percent Done design prototype

      I would really love to get your feedback on this. If you are interested in being a beta tester, feel free to reply to this topic or e-mail me at "hi at evrim dot io."

      By the way, this is almost completely a self-promotion post. If it is against the rules, I'd be happy to remove this.

      23 votes
    4. Tildee — A python library for interacting with Tildes

      Update! After a few hours of struggling I managed to set up Read the docs for Tildee, it should help using the library significantly. After getting some inspiration from TAPS I thought that maybe...

      Update! After a few hours of struggling I managed to set up Read the docs for Tildee, it should help using the library significantly.

      After getting some inspiration from TAPS I thought that maybe I try to work on something vaguely similar on my own. And after… some? hours of coding today I came up with this: tildee.py (source)
      It's a wrapper for the Tildes Public/Web API that is already used by the site internally to make it work. The obvious problem with that is that it will at one point break when this unstable API is changed. It can do basically all things a normal user can do with the notable exception of applying comment labels (because I haven't gotten around to that yet).

      Example of usage for a DM reply bot (result):

      import sys
      from tildee import TildesClient
      import time
      
      # Initialize client and log in, 2FA isn't supported yet and will probably break in horrible ways
      t = TildesClient("username", "password", base_url="https://localhost:4443", verify_ssl=False)
      
      while True:
          # Retrieve the "unread messages" page and get a list of the conversations there
          unread_message_ids = t.fetch_unread_message_ids()
          for mid in unread_message_ids:
              # Access the conversation history page; this also clears the "unread" flag 
              conversation = t.fetch_conversation(mid)
              # Get the text of the last message
              text = conversation.entries[-1].content_html
              # Abort if it's from the current user (I don't think this could actually happen)
              if conversation.entries[-1].author == t.username:
                  break
              print(f"Found a message by {conversation.entries[-1].author}")
              # If the message contains a reference, reply in kind
              if "hello there" in text.lower():
                  print("Replying…")
                  t.create_message(mid, f"General {conversation.entries[-1].author}! You are a bold one.")
              # Delay before processing next unread message
              time.sleep(3)
          # Delay before next unread check
          time.sleep(60)
      

      This has a lot of potential. Haven't yet figured out potential for what, but I'll take what I can get.
      I'd be really grateful if someone with a little more experience than me (that's not exactly a high bar :P) could give me some pointers on the project's structure and the "API design", hence the ask tag. Other creative ideas for what to use this for are appreciated, too.

      47 votes
    5. What are you reading these days? #22

      What are you reading currently? Fiction or non-fiction, any genre, any language! Tell us what you're reading, and talk a bit about it. Notes: I am aiming to make a list of all the books mentioned...

      What are you reading currently? Fiction or non-fiction, any genre, any language! Tell us what you're reading, and talk a bit about it.

      Notes: I am aiming to make a list of all the books mentioned in toplevel comments in these threads, see this wiki page. If you want to help with that, that'd really be appreciated, PM me please.

      Past weeks: Week #1 · Week #2 · Week #3 · Week #4 · Week #5 · Week #6 · Week #7 · Week #8 · Week #9 · Week #10 · Week #11 · Week #12 · Week #13 · Week #14 · Week #15 · Week #16 · Week #17 · Week #18 · Week #19 · Week #20 · Week #21

      15 votes
    6. Tildes User Script: Youtube Thumbnails Below Topic Title

      A screenshot. Following is a user script that embeds a thumbnail into the topic header. Was supposed to be trivial, but walking around the CSRP was not that easy. Luckily, someone had written a...

      A screenshot.

      Following is a user script that embeds a thumbnail into the topic header. Was supposed to be trivial, but walking around the CSRP was not that easy. Luckily, someone had written a nice useful custom Base64 encoder, because I spent more than an hour trying to get btoa to do the thing.

      // ==UserScript==
      // @name     tildesYoutubeThumbs
      // @version  1
      // @grant    GM.xmlHttpRequest
      // @namespace   tildes.net
      // @include     https://tildes.net/~*/*
      // ==/UserScript==
      
      let youtubeIcon = document.querySelector('div.topic-icon-youtube_com')
      
      if(youtubeIcon !== null) {
        let youtubeLink = youtubeIcon.nextSibling.nextSibling.href;
        let youtubeID = new URL(youtubeLink).searchParams.get('v');
        let thumbnailUrl = "https://img.youtube.com/vi/" + youtubeID + "/0.jpg";
      
        GM.xmlHttpRequest({
          method: "GET",
          url: thumbnailUrl,
          overrideMimeType: 'text/plain; charset=x-user-defined',
          onload: function(response) {
            if(response.status === 200) {
              let thumbElement = document.createElement('img');
              let thumbParentDiv = document.createElement('div');
              let header = document.querySelector('article.topic-full > header');
              let data = "data:image/jpeg;base64," + customBase64Encode(response.responseText);
              thumbElement.src = data;
              thumbElement.style = 'width: 60%; margin: auto';
              thumbElement.id = 'gk-youtube-thumbnail';
              thumbParentDiv.style = 'width: 100%; text-align:center;';
              header.appendChild(thumbParentDiv);
              thumbParentDiv.appendChild(thumbElement);
            }
          }
        });
      }
      
      // https://stackoverflow.com/questions/8778863/downloading-an-image-using-xmlhttprequest-in-a-userscript/8781262#8781262
      function customBase64Encode (inputStr) {
          var
              bbLen               = 3,
              enCharLen           = 4,
              inpLen              = inputStr.length,
              inx                 = 0,
              jnx,
              keyStr              = "ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz"
                                  + "0123456789+/=",
              output              = "",
              paddingBytes        = 0;
          var
              bytebuffer          = new Array (bbLen),
              encodedCharIndexes  = new Array (enCharLen);
      
          while (inx < inpLen) {
              for (jnx = 0;  jnx < bbLen;  ++jnx) {
                  /*--- Throw away high-order byte, as documented at:
                    https://developer.mozilla.org/En/Using_XMLHttpRequest#Handling_binary_data
                  */
                  if (inx < inpLen)
                      bytebuffer[jnx] = inputStr.charCodeAt (inx++) & 0xff;
                  else
                      bytebuffer[jnx] = 0;
              }
      
              /*--- Get each encoded character, 6 bits at a time.
                  index 0: first  6 bits
                  index 1: second 6 bits
                              (2 least significant bits from inputStr byte 1
                               + 4 most significant bits from byte 2)
                  index 2: third  6 bits
                              (4 least significant bits from inputStr byte 2
                               + 2 most significant bits from byte 3)
                  index 3: forth  6 bits (6 least significant bits from inputStr byte 3)
              */
              encodedCharIndexes[0] = bytebuffer[0] >> 2;
              encodedCharIndexes[1] = ( (bytebuffer[0] & 0x3) << 4)   |  (bytebuffer[1] >> 4);
              encodedCharIndexes[2] = ( (bytebuffer[1] & 0x0f) << 2)  |  (bytebuffer[2] >> 6);
              encodedCharIndexes[3] = bytebuffer[2] & 0x3f;
      
              //--- Determine whether padding happened, and adjust accordingly.
              paddingBytes          = inx - (inpLen - 1);
              switch (paddingBytes) {
                  case 1:
                      // Set last character to padding char
                      encodedCharIndexes[3] = 64;
                      break;
                  case 2:
                      // Set last 2 characters to padding char
                      encodedCharIndexes[3] = 64;
                      encodedCharIndexes[2] = 64;
                      break;
                  default:
                      break; // No padding - proceed
              }
      
              /*--- Now grab each appropriate character out of our keystring,
                  based on our index array and append it to the output string.
              */
              for (jnx = 0;  jnx < enCharLen;  ++jnx)
                  output += keyStr.charAt ( encodedCharIndexes[jnx] );
          }
          return output;
      }
      
      15 votes
    7. What have you done lately that you're proud of?

      Anything you've been working at lately and finally got it done? Anything you finally got around to finishing/starting? Anything big happening? Feel free to gush about anything you've done but want...

      Anything you've been working at lately and finally got it done? Anything you finally got around to finishing/starting? Anything big happening? Feel free to gush about anything you've done but want to talk about!

      Yesterday I decided to pick my acoustic guitar back up and learn Blackbird by The Beatles (Only mildly inspired by Kmac). Today I got it all down! Feeling super proud that I nailed a song like that so quickly after having played bass almost primarily for a while now.

      23 votes
    8. Has Wine begun to remove the need for linux software?

      I started using wine in about 2013 and I remember back then it was quite patchy and only worked on some programs/games. I used to have a rule that I stuck hard to that I would not buy any games...

      I started using wine in about 2013 and I remember back then it was quite patchy and only worked on some programs/games. I used to have a rule that I stuck hard to that I would not buy any games that did not have a linux version. But now in 2019 I have found that everything I have tried to run in wine has been so seamless and close to flawless that I hardly know its running in wine. I semi regularly buy games that only have windows version because I am mostly sure it will work and can get a refund if it doesn't.

      What does everyone else think about this?

      8 votes