code: public static String formatHumanFriendlyShortDate(final Context context, long timestamp) {
          long localTimestamp, localTime;
          long now = System.currentTimeMillis();
  
          TimeZone tz = TimeZone.getDefault();
          localTimestamp = timestamp + tz.getOffset(timestamp);
          localTime = now + tz.getOffset(now);
  
          long dayOrd = localTimestamp / 86400000L;
          long nowOrd = localTime / 86400000L;
  
          if (dayOrd == nowOrd) {
              return context.getString(R.string.day_title_today);
          } else if (dayOrd == nowOrd - 1) {
              return context.getString(R.string.day_title_yesterday);
          } else if (dayOrd == nowOrd + 1) {
              return context.getString(R.string.day_title_tomorrow);
          } else {
              return formatShortDate(context, new Date(timestamp));
          }
      }
docs: Returns "Today", "Tomorrow", "Yesterday", or a short date format.