Skip to content
GitLab
Explore
Sign in
Register
Primary navigation
Search or go to…
Project
E
emacs.d
Manage
Activity
Members
Labels
Plan
Issues
Issue boards
Milestones
Wiki
Code
Merge requests
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Snippets
Build
Pipelines
Jobs
Pipeline schedules
Artifacts
Deploy
Releases
Package Registry
Model registry
Operate
Environments
Terraform modules
Monitor
Incidents
Analyze
Value stream analytics
Contributor analytics
CI/CD analytics
Repository analytics
Model experiments
Help
Help
Support
GitLab documentation
Compare GitLab plans
Community forum
Contribute to GitLab
Provide feedback
Keyboard shortcuts
?
Snippets
Groups
Projects
Admin message
为了安全,强烈建议开启2FA双因子认证:User Settings -> Account -> Enable two-factor authentication!!!
Show more breadcrumbs
Liu Miao
emacs.d
Commits
2d67e43e
Commit
2d67e43e
authored
4 years ago
by
MoScribe
Browse files
Options
Downloads
Patches
Plain Diff
add installation of use-package
parent
19132567
No related branches found
No related tags found
No related merge requests found
Changes
2
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
init.el
+7
-3
7 additions, 3 deletions
init.el
lisp/keybinding.el
+0
-71
0 additions, 71 deletions
lisp/keybinding.el
with
7 additions
and
74 deletions
init.el
+
7
−
3
View file @
2d67e43e
...
@@ -134,6 +134,7 @@
...
@@ -134,6 +134,7 @@
(
add-hook
'prog-mode-hook
(
lambda
()
(
setq
truncate-lines
t
)))
(
add-hook
'prog-mode-hook
(
lambda
()
(
setq
truncate-lines
t
)))
;;; Packages===============================================================================
;;; Packages===============================================================================
(
require
'package
)
(
setq
package--init-file-ensured
t
(
setq
package--init-file-ensured
t
package-enable-at-startup
nil
package-enable-at-startup
nil
package-archives
'
((
"gnu"
.
"http://elpa.emacs-china.org/gnu/"
)
package-archives
'
((
"gnu"
.
"http://elpa.emacs-china.org/gnu/"
)
...
@@ -144,6 +145,11 @@
...
@@ -144,6 +145,11 @@
(
if
(
<
emacs-major-version
27.0
)
(
if
(
<
emacs-major-version
27.0
)
(
package-initialize
)
(
package-initialize
)
)
)
(
or
(
package-installed-p
'use-package
)
(
progn
;; (package-refresh-contents)
(
package-install
'use-package
))
)
;;---------------------------------------------------------------------------------------
;;---------------------------------------------------------------------------------------
;;; Completion=============================================================================
;;; Completion=============================================================================
...
@@ -315,13 +321,11 @@
...
@@ -315,13 +321,11 @@
"f s"
'save-buffer
"f s"
'save-buffer
"SPC"
'counsel-M-x
"SPC"
'counsel-M-x
"s s"
'swiper
"s s"
'swiper
;; "s r" 'helm-swoop
"h i"
'counsel-imenu
"h i"
'counsel-imenu
;; "h f" 'helm-flycheck
;; buffer
;; buffer
"b d"
'kill-current-buffer
"b d"
'kill-current-buffer
"b k"
'kill-buffer
"b k"
'kill-buffer
;;
"b b" '
helm-mini
"b b"
'
counsel-switch-buffer
;; magit-----------------------------------
;; magit-----------------------------------
"g s"
'magit-status
"g s"
'magit-status
"g d"
'magit-diff-range
"g d"
'magit-diff-range
...
...
This diff is collapsed.
Click to expand it.
lisp/keybinding.el
deleted
100644 → 0
+
0
−
71
View file @
19132567
;;; keybinding.el --- This is a file about keyboard setting
;;; Commentary:
;; Here gets some keyboards that could be used when the
;; Emacs started.
;;; code:
(
require
'user-fun
)
(
require
'basic
)
(
defun
install-key-pack
()
" "
(
let
((
key-pack-list
'
(
evil
)))
(
dolist
(
pack
key-pack-list
)
(
require-package
pack
))
))
(
install-key-pack
)
;;; Evil
;;=====================================================================
(
require
'evil
)
(
evil-mode
1
)
;;=====================================================================
;;; helm
;; ==================================================================
(
global-set-key
(
kbd
"M-x"
)
#'
helm-M-x
)
(
global-set-key
(
kbd
"C-x C-f"
)
#'
helm-find-files
)
;; ==================================================================
;;; Org mode global keys
;;==================================================================
(
global-set-key
"\C-cl"
'org-store-link
)
(
global-set-key
"\C-ca"
'org-agenda
)
(
global-set-key
"\C-cc"
'org-capture
)
(
global-set-key
"\C-cb"
'org-iswitchb
)
;;==================================================================
;;; Youdao search
;;==================================================================
(
global-set-key
(
kbd
"M-s s"
)
'youdao-dictionary-search-from-input
)
(
global-set-key
(
kbd
"M-s t"
)
'youdao-dictionary-search-at-point+
)
;;==================================================================
;;; Search
;;==================================================================
(
global-set-key
"\C-s"
'helm-swoop-without-pre-input
)
;;; Recentf mode
;;------------------------------------------------------------------------
(
global-set-key
(
kbd
"\C-cr"
)
'recentf-open-files
)
;;------------------------------------------------------------------------
;;; disaster
;; ===================================================================================
(
global-set-key
(
kbd
"\C-cd"
)
'disaster
)
;; ===================================================================================
;;; windows jump
;;------------------------------------------------------------------------------------
(
global-set-key
(
kbd
"M-s r"
)
'window-jump-right
)
(
global-set-key
(
kbd
"M-s l"
)
'window-jump-left
)
(
global-set-key
(
kbd
"M-s u"
)
'window-jump-up
)
(
global-set-key
(
kbd
"M-s d"
)
'window-jump-down
)
;;------------------------------------------------------------------------------------
(
provide
'keybinding
)
;;; keyboard.el ends here
This diff is collapsed.
Click to expand it.
Preview
0%
Loading
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Save comment
Cancel
Please
register
or
sign in
to comment