Skip to content
Snippets Groups Projects
Commit 1606642e authored by Stéphane Del Pino's avatar Stéphane Del Pino
Browse files

version initiale

parents
No related branches found
No related tags found
No related merge requests found
/recentf
auto-save-list
*~
\#*
*.elc
\ No newline at end of file
#+STARTUP: showall hidestars
* Infos
Cette configuration d'emacs est grandement due à Mike Zamansky
L'installation la plus simple de cette configuration se résume à
renommer le répertoire courant en
#+BEGIN_SRC shell
~/.emacs.d
#+END_SRC
* Emacs client
Emacs fonctionne plus rapidement lorsqu'il est lancé en mode client
(plusieurs client s'attachent à un même serveur). Pour bénéficier de
cette optimisation ajouter les alias suivants à votre shell
#+BEGIN_SRC shell
alias emacs="emacsclient -q -a '' -c"
alias kill-emacs="emacsclient -q -e '(let ((last-nonmenu-event nil))(save-buffers-kill-emacs))'"
#+END_SRC
* Version originale par Mike Zamansky
Pour une excellente série tutoriels ainsi que la construction pas a
pas de configurations, voir ci-dessous
** Message de Mike Zamansky
For a list of all posts and videos check out http://cestlaz.github.io/stories/emacs
init.el 0 → 100644
(setq max-lisp-eval-depth 10000)
(setq max-specpdl-size 10000)
(require 'package)
(setq package-enable-at-startup nil)
(add-to-list 'package-archives
'("melpa" . "http://melpa.org/packages/"))
(add-to-list 'package-archives
'("gnu" . "http://elpa.gnu.org/packages/"))
;; (add-to-list 'package-archives
;; '("melpa3" . "http://www.mirrorservice.org/sites/stable.melpa.org/packages/"))
(package-initialize)
;; Bootstrap `use-package'
(unless (package-installed-p 'use-package)
(package-refresh-contents)
(package-install 'use-package))
; If you like a tabbar
(use-package tabbar
:ensure t
:config
(tabbar-mode 1))
(org-babel-load-file (expand-file-name "~/.emacs.d/myinit.org"))
(custom-set-variables
;; custom-set-variables was added by Custom.
;; If you edit it by hand, you could mess it up, so be careful.
;; Your init file should contain only one such instance.
;; If there is more than one, they won't work right.
'(all-the-icons-ivy-buffer-commands (quote (ivy-switch-buffer-other-window ivy-switch-buffer)))
'(clang-format-executable "/usr/bin/clang-format-8")
'(elpy-rpc-backend "jedi" t)
'(hydra-hint-display-type (quote posframe))
'(org-confirm-babel-evaluate nil)
'(org-default-notes-file (concat org-directory "/notes.org"))
'(org-directory "~/Sync/orgfiles")
'(org-export-html-postamble nil)
'(org-hide-leading-stars t)
'(org-src-fontify-natively t)
'(org-startup-folded (quote overview))
'(org-startup-indented t)
'(package-selected-packages
(quote
(alect-theme zero-dark-theme autumn-light-theme solarized-dark-theme misterioso misterioso-theme zenburn sourcerer-theme flycheck-pos-tip flycheck-clojure ox-reveal posframe processing-snippets processing-mode rg deadgrep flycheck-rust cargo racer yasnippet-classic-snippets rustic lsp-rust lsp-java company-lsp lsp-ui lsp-mode lsp yasnippet-snippets counsel-spotify exec-path-from-shell easy-kill auto-yasnippet org-pdfview pdf-tools atomic-chrome mingus simple-mpc pcre2el ag wgrep-ag wgrep haskell-mode aggressive-indent treemacs-projectile treemacs prodigy origami dumb-jump cider ggtags circe-notifications circe org-gcal mu4e-alert git-timemachine git-gutter magit hydra default-text-scale smartparens projectile auctex tern-auto-complete tern js2-refactor ac-js2 js2-mode emmet-mode web-mode iedit expand-region multiple-cursors hungry-delete beacon undo-tree virtualenvwrapper elpy flycheck doom-modeline doom-themes tao-theme poet-theme faff-theme zerodark-theme alect-themes moe-theme base16-theme zenburn-theme color-theme-modern company-jedi irony-eldoc company-irony company counsel ace-window htmlize noflet org-bullets which-key try use-package)))
'(sp-escape-quotes-after-insert nil t))
(setq max-lisp-eval-depth 10000)
(setq max-specpdl-size 10000)
(require 'package)
(setq package-enable-at-startup nil)
(add-to-list 'package-archives
'("melpa" . "https://melpa.org/packages/"))
(add-to-list 'package-archives
'("gnu" . "https://elpa.gnu.org/packages/"))
;; (add-to-list 'package-archives
;; '("melpa3" . "http://www.mirrorservice.org/sites/stable.melpa.org/packages/"))
(package-initialize)
;; Bootstrap `use-package'
(unless (package-installed-p 'use-package)
(package-refresh-contents)
(package-install 'use-package))
(org-babel-load-file (expand-file-name "~/.emacs.d/myinit.org"))
(custom-set-faces
;; custom-set-faces was added by Custom.
;; If you edit it by hand, you could mess it up, so be careful.
;; Your init file should contain only one such instance.
;; If there is more than one, they won't work right.
'(aw-leading-char-face ((t (:inherit ace-jump-face-foreground :height 3.0)))))
(put 'dired-find-alternate-file 'disabled nil)
(put 'dired-find-alternate-file 'disabled nil)
(byte-recompile-directory (expand-file-name "~/.emacs.d") 0)
;; Local Variables:
;; byte-compile-warnings: (not free-vars)
;; End:
This diff is collapsed.
This diff is collapsed.
nil
\ No newline at end of file
import random
def f(x):
return random.randrange(1, x)
for i in range(2,10):
print f(i)
if __name__ == '__main__':
hello
class myclass(somethingelse):
"""documentation
"""
def __init__(self, some_args):
super(myclass, self).__init__()
self.some_args = some_args
<!DOCTYPE html>
<html lang="en">
<head>
<meta charset="utf-8"/>
<title>My Awesome Presentation</title>
<meta name="author" content="(Mike Zamansky)"/>
<style type="text/css">
.underline { text-decoration: underline; }
</style>
<link rel="stylesheet" href="http://cdn.jsdelivr.net/reveal.js/3.0.0/css/reveal.css"/>
<link rel="stylesheet" href="http://cdn.jsdelivr.net/reveal.js/3.0.0/css/theme/sky.css" id="theme"/>
<!-- If the query includes 'print-pdf', include the PDF print sheet -->
<script>
if( window.location.search.match( /print-pdf/gi ) ) {
var link = document.createElement( 'link' );
link.rel = 'stylesheet';
link.type = 'text/css';
link.href = 'http://cdn.jsdelivr.net/reveal.js/3.0.0/css/print/pdf.css';
document.getElementsByTagName( 'head' )[0].appendChild( link );
}
</script>
</head>
<body>
<div class="reveal">
<div class="slides">
<section id="sec-title-slide"><h1 class="title">My Awesome Presentation</h1><h2 class="author">Mike Zamansky</h2><p class="date">Created: 2016-07-19 Tue 11:44</p>
</section>
<section>
<section id="slide-orgheadline1">
<h2 id="orgheadline1">Slide 1</h2>
<p>
here's some text
</p>
</section>
</section>
<section>
<section id="slide-orgheadline4">
<h2 id="orgheadline4">Slide 2</h2>
<div class="outline-text-2" id="text-orgheadline4">
</div></section>
<section id="slide-orgheadline2">
<h3 id="orgheadline2">subslide 1</h3>
</section>
<section id="slide-orgheadline3">
<h3 id="orgheadline3">subslide 2</h3>
</section>
</section>
<section>
<section id="slide-orgheadline5">
<h2 id="orgheadline5">Slide 3</h2>
<ul>
<li class="fragment roll-in">list item 1</li>
<li class="fragment roll-in"><p>
list item 2
</p>
<table border="2" cellspacing="0" cellpadding="6" rules="groups" frame="hsides">
<colgroup>
<col class="org-right" />
<col class="org-right" />
<col class="org-right" />
</colgroup>
<thead>
<tr>
<th scope="col" class="org-right">a</th>
<th scope="col" class="org-right">b</th>
<th scope="col" class="org-right">c</th>
</tr>
</thead>
<tbody>
<tr>
<td class="org-right">1</td>
<td class="org-right">2</td>
<td class="org-right">3</td>
</tr>
<tr>
<td class="org-right">4</td>
<td class="org-right">5</td>
<td class="org-right">6</td>
</tr>
</tbody>
</table></li>
</ul>
</section>
</section>
<section>
<section id="slide-orgheadline6">
<h2 id="orgheadline6">slide 4</h2>
<div class="org-src-container">
<pre class="src src-python"><span style="color: #F0DFAF; font-weight: bold;">def</span> <span style="color: #93E0E3;">f</span>(x):
<span style="color: #F0DFAF; font-weight: bold;">return</span> x + 1
<span style="color: #F0DFAF; font-weight: bold;">print</span> f(5)
</pre>
</div>
</section>
</section>
</div>
</div>
<script src="http://cdn.jsdelivr.net/reveal.js/3.0.0/lib/js/head.min.js"></script>
<script src="http://cdn.jsdelivr.net/reveal.js/3.0.0/js/reveal.js"></script>
<script>
// Full list of configuration options available here:
// https://github.com/hakimel/reveal.js#configuration
Reveal.initialize({
controls: true,
progress: true,
history: false,
center: true,
slideNumber: 'c',
rollingLinks: false,
keyboard: true,
overview: true,
theme: Reveal.getQueryHash().theme, // available themes are in /css/theme
transition: Reveal.getQueryHash().transition || 'default', // default/cube/page/concave/zoom/linear/fade/none
transitionSpeed: 'default',
multiplex: {
secret: '', // null if client
id: '', // id, obtained from socket.io server
url: '' // Location of socket.io server
},
// Optional libraries used to extend on reveal.js
dependencies: [
{ src: 'http://cdn.jsdelivr.net/reveal.js/3.0.0/lib/js/classList.js', condition: function() { return !document.body.classList; } },
{ src: 'http://cdn.jsdelivr.net/reveal.js/3.0.0/plugin/markdown/marked.js', condition: function() { return !!document.querySelector( '[data-markdown]' ); } },
{ src: 'http://cdn.jsdelivr.net/reveal.js/3.0.0/plugin/markdown/markdown.js', condition: function() { return !!document.querySelector( '[data-markdown]' ); } },
{ src: 'http://cdn.jsdelivr.net/reveal.js/3.0.0/plugin/zoom-js/zoom.js', async: true, condition: function() { return !!document.body.classList; } },
{ src: 'http://cdn.jsdelivr.net/reveal.js/3.0.0/plugin/notes/notes.js', async: true, condition: function() { return !!document.body.classList; } }]
});
</script>
</body>
</html>
#+REVEAL_THEME: sky
#+OPTIONS: toc:nil num:nil
#+TITLE: My Awesome Presentation
#+AUTHOR: Mike Zamansky
* Slide 1
here's some text
* Slide 2
** subslide 1
** subslide 2
* Slide 3
#+ATTR_REVEAL: :frag (roll-in)
- list item 1
- list item 2
| a | b | c |
|---+---+---|
| 1 | 2 | 3 |
| 4 | 5 | 6 |
|---+---+---|
* slide 4
#+BEGIN_SRC python
def f(x):
return x + 1
print f(5)
#+END_SRC
# -*- mode: snippet -*-
# name: post
# key: post
# expand-env: ((yas-indent-line 'fixed) (yas-wrap-around-region 'nil))
# --
---
title: ${1:`(capitalize (replace-regexp-in-string "-\\|_" " " (file-name-base))))`}
date: `(format-time-string "%Y-%m-%dT%H:%M:%S-04:00" (current-time))`
tags:
categories:
draft: true
---
$0
\ No newline at end of file
# -*- mode: snippet -*-
# name: flask
# key: flask
# expand-env: ((yas-indent-line 'fixed) (yas-wrap-around-region 'nil))
# --
from flask import Flask, render_template
app = Flask(__name__)
@app.route("/")
def index():
return "hello"
$0
if __name__ == "__main__":
app.debug = True
app.run(host="0.0.0.0", port=8000)
# -*- mode: snippet -*-
# name: vue
# key: vue
# expand-env: ((yas-indent-line 'fixed) (yas-wrap-around-region 'nil))
# --
<template>
$0
</template>
<script>
export default {
name :'$1',
data : function(){
return {
}
},
methods: {
},
components:{
}
}
</script>
<style scoped>
</style>
\ No newline at end of file
nil
\ No newline at end of file
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment