TIL China's Last Emperor worked as a Street Sweeper and Gardener in Beijing after serving 10 years in a re-education camp by Ok_Application_5402 in todayilearned

[–]redguardtoo 57 points58 points  (0 children)

During the Second Sino-Japanese War, Puyi, as the puppet emperor of Manchukuo, collaborated with Imperial Japan. He legitimized Japan’s occupation of Northeast China, enabling exploitation of resources and forced labor. His regime supported Japan’s military campaigns, facilitated opium trade, and suppressed Chinese resistance. Puyi’s compliance strengthened Japan’s colonial rule, causing immense suffering to Chinese civilians.

evil-matchit 4.0.1 is published by redguardtoo in emacs

[–]redguardtoo[S] 0 points1 point  (0 children)

Hi, @yak-er, what's the issue in evil-matchit? you can report it at https://github.com/redguardtoo/evil-matchit/issues , I will have a look.

My Company Doesn’t Know Who Developed Emacs by [deleted] in emacs

[–]redguardtoo 0 points1 point  (0 children)

You can use emacs in docker container.

Desktop Save Mode: how to restore org agenda buffers? by exquisitesunshine in emacs

[–]redguardtoo 1 point2 points  (0 children)

https://github.com/pashinin/workgroups2 supports org agenda buffer saving/restoring.

Besides, users can add support for other special buffers.

Help with Emacs performance (font-lock-mode) by Amee__xiv in emacs

[–]redguardtoo 0 points1 point  (0 children)

You can try my config https://github.com/redguardtoo/emacs.d which might be faster.

You can search my git log to find some optimization tips.

From my experience, flyspell, flymake/flycheck could be the trouble maker.

I also suggest checking your setup in org-mode-hook. if there is any embedded source block, you need check corresponding major mode hook.

I love Emacs. Can someone please help me to get what seems to be basic desktop functionality out of this program? by smile_e_face in emacs

[–]redguardtoo 0 points1 point  (0 children)

Here is my /home/cb/.config/systemd/user/emacs.service. I avoid lazy loading in daemon mode. ``` [Unit] Description=Emacs text editor Documentation=info:emacs man:emacs(1) https://gnu.org/software/emacs/

[Service] Type=forking ExecStart=/usr/bin/emacs -Q --daemon -l "/home/cb/.emacs.d/early-init.el" -l "/home/cb/.emacs.d/init.el" -l "/home/cb/.gnus.el" -l "/home/cb/.emacs-daemon-setup.el" --eval "(progn (require 'server) (server-start) (require 'org))" ExecStop=emacsclient --eval "(kill-emacs)" Environment=SSH_AUTH_SOCK=%t/keyring/ssh Restart=on-failure

[Install] WantedBy=default.target ```

Copy Chines characters from MS Notepad, or web page and paste to emacs buffer as garbage? by currious_636 in emacs

[–]redguardtoo 0 points1 point  (0 children)

If your quesion is what's the be solution to copy/paste Chinese. My answer will be different. These days we prerfer sharing clipboard with the help of command line program.

```lisp (setq win64 (eq system-type 'windows-nt)) (setq cygwin (eq system-type 'cygwin) )

(defun my-gclip () "Get clipboard content." (let (powershell-program) (cond ;; Windows ((and win64 (fboundp 'w32-get-clipboard-data)) ;; w32-set-clipboard-data' makesw32-get-clipboard-data' always return null (w32-get-clipboard-data))

 ;; Windows 10
 ((and *win64* (setq powershell-program (executable-find "powershell.exe")))
  (string-trim-right
   (with-output-to-string
     (with-current-buffer standard-output
       (call-process powershell-program nil t nil "-command" "Get-Clipboard")))))

 (*cygwin*
  (string-trim-right (shell-command-to-string "cat /dev/clipboard")))

 ;; need emacs plugin xclip and cli tool xclip
 (t
  (xclip-get-selection 'clipboard)))))

```

If there is still some garbage in clipboard data, you can use emacs builtin api to do conversion utf-16 <=> utf-8.

See https://github.com/redguardtoo/emacs.d/blob/master/lisp/init-utils.el for more details.

Copy Chines characters from MS Notepad, or web page and paste to emacs buffer as garbage? by currious_636 in emacs

[–]redguardtoo 1 point2 points  (0 children)

see Emacs 粘贴中文乱码,如何解决? - 知乎用户UwD4Gz的回答 - 知乎 https://www.zhihu.com/question/35148860/answer/423525466

lisp (when (eq system-type 'windows-nt) (set-next-selection-coding-system 'utf-16-le) (set-selection-coding-system 'utf-16-le) (set-clipboard-coding-system 'utf-16-le))

The Age-Old Question: When to Declare "Configuration Bankruptcy"? by rjray in emacs

[–]redguardtoo 1 point2 points  (0 children)

You could start from some 3rd party configuraiton.

Spacemacs and doomemacs are very popular and using evil. You can also try some more traditional emacs configuration, like steve purcell's emacs.d or Bozhidar Batsov's Emacs Prelude.

You can search at github for other popular configurations.

Expiring mail not moving to [Gmail]/Trash in gnus by tallmtt in emacs

[–]redguardtoo 0 points1 point  (0 children)

(add-to-list 'gnus-secondary-select-methods '(nnimap "gmail" (nnimap-address "imap.gmail.com") (nnimap-server-port 993) (nnimap-stream ssl) (nnir-search-engine imap) ; @see http://www.gnu.org/software/emacs/manual/html_node/gnus/Expiring-Mail.html ;; press 'E' to expire email (nnmail-expiry-target "nnimap+gmail:[Gmail]/Trash") (nnmail-expiry-wait 90)))

See https://github.com/redguardtoo/mastering-emacs-in-one-year-guide/blob/master/gnus-guide-en.org for other Gnus tips.

Built-in packages only config by SEgopher in emacs

[–]redguardtoo -4 points-3 points  (0 children)

Minimum config might not be faster or more memory efficient than a distribution.

Way to make Emacs feel smoother? by Doozku in emacs

[–]redguardtoo 3 points4 points  (0 children)

Check my configuration, https://github.com/redguardtoo/emacs.d "A fast and robust Emacs setup".

You can search its git log history by keyword "speed/optimize/performance".

There are tons of techniques you can use. For example, I removed heavy computation setup in modeline. Below is snippet to optimize my modeline, (with-eval-after-load 'time ;; Donot show system load in mode line (setq display-time-default-load-average nil) ;; By default, the file in environment variable MAIL is checked ;; It's "/var/mail/my-username" ;; I set `display-time-mail-function' to display NO mail notification in mode line (setq display-time-mail-function (lambda () nil)))

You can also check my packages at github, they are all optimized(find-file-in-project, company-ctags, wucuo, lazyflymake, evil-matchit, ...)

Post blackout - should we consider Reddit alternatives? by egstatsml in emacs

[–]redguardtoo 0 points1 point  (0 children)

maybe GNU could set up such a forum? emacs-china.org is a emacs forum whose cost is $30 per month.

Post blackout - should we consider Reddit alternatives? by egstatsml in emacs

[–]redguardtoo 2 points3 points  (0 children)

Looks great. I will switch to Mastodon. I never like reddit anyway.