zoukankan      html  css  js  c++  java
  • Linux Submitting Patch

    Linux Submitting Patch

    Linux Submitting Patch

    For a long time, I've been wondering what it would be like to submit patches to the linux kernel. Now I find a chance to do that.

    This post records the necessary steps for preparing and submitting patches to the kernel mail list.

    1 Get the latest kernel source code from git. It is recommeded to use Torvalds's branch.

    git clone git://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git

    2 Create a new branch within git, in which the modification takes place.

    git branch wujing(any branch name)
    git checkout wujing

    After this step, the working branch is switched to wujing. You can check the status with :

    git branch

    The branch name with a star sign in front is the currently active branch.

    3 Commit the changes.

    git commit -m "modification summary" ./*

    In the above command, it is assumed that the modified files is located in the current working directory. Normally, this directory can be the top level source directory.

    4 Make patch with git.

    git format-patch master -s

    This command creates a patch against the master branch. With all the necessary information of a standard patch.

    5 Configure the msmtp service and send the patch to the matainers.

    apt install msmtp

    The configuration file of msmtp(~/.msmtprc) using hotmail is as follows:

     1: defaults
     2: logfile ~/.msmtp.log
     3: #hotmail
     4: account hotmail
     5: protocol smtp
     6: host smtp.live.com
     7: from xxx@hotmail.com
     8: user xxx@hotmail.com
     9: password xxxx
    10: port 25
    11: auth login
    12: tls on
    13: tls_trust_file /etc/ssl/certs/ca-certificates.crt
    14: syslog LOG_MAIL
    15: 
    16: # Set a default account
    17: account default : hotmail
    

    To find the matainers, use the following command:

    ./scripts/get_maintainer.pl -f xx

    Finally, to send the patch to the target users:

    git send-email –smtp-server /usr/bin/msmtp –to xxx@qq.com –cc xxx@cqu.edu.cn xxx.patch

    Author: wujing

    Created: 2016-08-22 Mon 17:09

    Emacs 24.5.1 (Org mode 8.2.10)

  • 相关阅读:
    xgqfrms™, xgqfrms® : xgqfrms's offical website of GitHub!
    xgqfrms™, xgqfrms® : xgqfrms's offical website of GitHub!
    svn 启动项目报错,项目被lock
    BigDecimal 用法详解
    MySQL 规范
    Tomcat 详解URL请求
    Tomcat Servlet工作原理
    Tomcat Context容器和Wrapper容器
    Tomcat 核心组件 Container容器相关
    Tomcat 核心组件 Connector
  • 原文地址:https://www.cnblogs.com/wujingcqu/p/5796307.html
Copyright © 2011-2022 走看看