Adding several text parts to one file in sequence
Here we go, I would create some "util" namespace to write some helper code:

./util/index.js

const bPromise = require('bluebird');

const fs = require('fs');

const readFile = bPromise.promisify(fs.readFile);

const appendFile = bPromise.promisify(fs.appendFile);

const createWS = filename =&gt; {
    var writer = fs.createWriteStream(filename, {defaultEncoding: 'utf8', flags : 'a'});
    return {
        write : bPromise.promisify(writer.write.bind(writer))
    }
}

module.exports = {
    readFile, 
    appendFile,
    createWS
}


Thanks to bluebird we can convert functions with callback functions into functions that returns a resolved or rejected Promise with the result value. So that is what it's done in "./util/index.js".

In your main file:

var { readFile, appendFile, createWS} = require('./util');

var filename = "content.txt";
var writer = createWS(filename);
var xyz = ['x', 'y', 'z'];

// (1) Read 'head.txt'
readFile('head.txt', 'utf8')
.then( head =&gt; appendFile(filename, head))
.then( ()=&gt;{
    // Head appended
    var a = '...';
    var b = '...';
    var ab = a + b;
    return appendFile(filename, ab);
})
.then( ()=&gt;{
    // ab appended
    //return xyz.reduce((a, b)=&gt; a.then( ()=&gt; writer.write('...' + b + '...') ), Promise.resolve(null) )
    // or just 
    return writer.write(xyz.map(el=&gt;'...' + el + '...').join(''));
})
.then( ()=&gt;{
    return writer.write(xyz.map(el=&gt;'...' + el + '...').join(''));
})
.then( ()=&gt;{
    return readFile('footer.txt', 'utf8')
        .then( footer =&gt; writer.write(footer))
})
.then( ()=&gt;{})
.catch(console.error.bind(console));


Now looks very nice and it's clear. There's no need (Like in your code) to execute synchronous functions.

Check the ES5 code. 

./util/index.js

var bPromise = require('bluebird');

var fs = require('fs');

var readFile = bPromise.promisify(fs.readFile);

var appendFile = bPromise.promisify(fs.appendFile);

var createWS = function createWS(filename) {
    var writer = fs.createWriteStream(filename, { defaultEncoding: 'utf8', flags: 'a' });
    return {
        write: bPromise.promisify(writer.write.bind(writer))
    };
};

module.exports = {
    readFile: readFile,
    appendFile: appendFile,
    createWS: createWS
};


index.js

var _require = require('./util');

var readFile = _require.readFile;
var appendFile = _require.appendFile;
var createWS = _require.createWS;


var filename = "content.txt";
var writer = createWS(filename);
var xyz = ['x', 'y', 'z'];

// (1) Read 'head.txt'
readFile('head.txt', 'utf8').then(function (head) {
    return appendFile(filename, head);
}).then(function () {
    // Head appended
    var a = '...';
    var b = '...';
    var ab = a + b;
    return appendFile(filename, ab);
}).then(function () {
    // ab appended
    //return xyz.reduce((a, b)=&gt; a.then( ()=&gt; writer.write('...' + b + '...') ), Promise.resolve(null) )
    // or just 
    return writer.write(xyz.map(function (el) {
        return '...' + el + '...';
    }).join(''));
}).then(function () {
    return writer.write(xyz.map(function (el) {
        return '...' + el + '...';
    }).join(''));
}).then(function () {
    return readFile('footer.txt', 'utf8').then(function (footer) {
        return writer.write(footer);
    });
}).then(function () {}).catch(console.error.bind(console));