Skip to content

Instantly share code, notes, and snippets.

View stasm's full-sized avatar

Stanisław Małolepszy stasm

View GitHub Profile
brandShorterName
browser/branding/official/brand.dtd:brandShorterName
Firefox
mail/branding/thunderbird/brand.dtd:brandShorterName
Thunderbird
brandShortName
browser/branding/official/brand.dtd:brandShortName
Firefox
mail/branding/thunderbird/brand.dtd:brandShortName
Thunderbird
@stasm
stasm / 1.md
Last active October 23, 2023 06:48

A message with a variable:

Hello, {$username}!

A message with an annotated variable:

{#input $date :datetime month=long day=numeric}
Today is {$date}.
@stasm
stasm / README.md
Last active October 15, 2023 11:40
MessageFormat Beauty Contest

When evaluating each option below, please keep in mind the following questions:

  1. What's going on in the examples? What's your first reaction to seeing them?
  2. What do you like about each example? Any good ideas worth transplanting to other options? Feel free to mix and match.
  3. What do you dislike about each example? Imagine you have to work with this syntax in the future (it will one day be available directly in JavaScript!). What do you thikn is going to be annoying?
  4. What do you think the output of help, hello and notif is exactly (including leading and trailing whitespace)?
  5. How would you add a single space in front of all presented messages, to make it part of the translatable text?
  6. How would you add a newline in front of all presented messages, to make it part of the translatable text?
@stasm
stasm / migrate-mobile.sh
Created December 20, 2011 09:34
Migrate your mobile/ directory to the new layout with mobile/android and mobile/xul
#!/bin/bash
function msg {
echo
echo "########################################"
echo -e $@
echo "########################################"
echo
}
@stasm
stasm / workload-low.ftl
Last active February 27, 2023 13:42
An example of a large file, FTL v0.2.
# This Source Code Form is subject to the terms of the Mozilla Public
# License, v. 2.0. If a copy of the MPL was not distributed with this
# file, You can obtain one at http://mozilla.org/MPL/2.0/.
# browser/locales/en-US/browser/menubar.ftl
[[ File menu ]]
@stasm
stasm / .env
Last active December 17, 2021 18:20
Pontoon in Docker
SECRET_KEY=hiphopopotamus
DJANGO_DEV=True
DJANGO_DEBUG=True
DATABASE_URL=postgres://pontoon:pontoon@localhost/pontoon
SESSION_COOKIE_SECURE=False
SITE_URL=http://localhost:8000
FXA_CLIENT_ID=2651b9211a44b7b2
FXA_SECRET_KEY=a3cafccbafe39db54f2723f8a6f804c337e362950f197b5b33050d784129d570
FXA_OAUTH_ENDPOINT=https://oauth-stable.dev.lcip.org/v1
FXA_PROFILE_ENDPOINT=https://stable.dev.lcip.org/profile/v1
@stasm
stasm / elems.txt
Created May 7, 2020 12:34
vars and elems used in voice-web/web/locales/en/
articleLink
b
bold
browseWrap
datasetLink
discourseLink
githubLink
goalPercentage
italic
languagesLink
@stasm
stasm / compat.diff
Created April 21, 2020 13:40
@fluent compat vs ES2018
diff -wru compat/fluent-bundle.js es2018/fluent-bundle.js
--- compat/fluent-bundle.js 2020-04-21 14:45:46.219383600 +0200
+++ es2018/fluent-bundle.js 2020-04-21 14:46:02.403757100 +0200
@@ -8,190 +8,6 @@
})(this, function (exports) {
"use strict";
- function _defineProperty(obj, key, value) {
- if (key in obj) {
- Object.defineProperty(obj, key, {
../../gecko-strings/browser/browser/aboutTabCrashed.ftl
Choose { crashed-restore-tab-button } to reload the page.
Choose { crashed-restore-tab-button } or { crashed-restore-all-button } to reload the page/pages.
Choose { crashed-restore-tab-button } or { crashed-restore-all-button } to reload the page/pages.
../../gecko-strings/browser/browser/browserContext.ftl
{ main-context-menu-back.tooltiptext }
{ main-context-menu-back.aria-label }
{ main-context-menu-forward.tooltiptext }
{ main-context-menu-forward.aria-label }
{ main-context-menu-reload.aria-label }

Keybase proof

I hereby claim:

  • I am stasm on github.
  • I am sta (https://keybase.io/sta) on keybase.
  • I have a public key ASCqb0sg6M1_OWVxrTG4YhF6GNuUjBD3ji1aeWyR93WTtQo

To claim this, I am signing this object: